위에서 비슷한 현상을 찾았다.
여기서 주목한건 tasks.yml에 오직 description과 agent만 설정하라는 것임. 나는 다른 것도 설정해놓고 있었다.
task의 컨텍스트 설정도 다음처럼 해야 한다.
@task
def news_reporting_task(self) -> Task:
return Task(
config=self.tasks_config["news_reporting_task"],
expected_output="A report on the latest news on the given topic to korean.",
context=self.news_research_task(), #이렇게 해야 callable해지는듯..?
output_file="news_report.md"
)
근데도 이런 오류가 나고 있다…?
재밌는건 위 사람도 같은 오류를 발견했고, 해결책을 줬다는 것임.
context를 이렇게 배열로 감싸줘야 한다.
다음 마주친 에러
@time_check
def run():
ai_agent = NewsAgent()
crew_instance = ai_agent.crew()
result = crew_instance.kickoff(input = {"topic": "nvidia_korea"})
print(result)
if __name__ == "__main__":
run()