Skip to content

llm chain of thought in ascore attempts to run a synchronous call to Async Client #2497

Open
@rmenziejr

Description

@rmenziejr

The llm chain of thought function runs generate_string instead of agenerate_string even though using ascore.

chain_of_thought=self.llm_chain_of_thought,

fix would be just to add a function:

async def allm_chain_of_thought(self) -> str:
        prompt = template.G_EVAL_COT_TEMPLATE.format(
            task_introduction=self.task_introduction,
            evaluation_criteria=self.evaluation_criteria,
        )
        return await self._model.agenerate_string(input=prompt)

and update the ascore to the new function and await it

Metadata

Metadata

Assignees

No one assigned

    Labels

    Feature RequestNew feature or requestimprovementidea on how to make a feature better

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions