File tree Expand file tree Collapse file tree 6 files changed +1
-20
lines changed
news-guide/backend/app/agents Expand file tree Collapse file tree 6 files changed +1
-20
lines changed Original file line number Diff line number Diff line change 1717
1818from .cat_state import CatState
1919from .cat_store import CatStore
20- from .memory_store import MemoryStore
2120from .widgets .name_suggestions_widget import CatNameSuggestion , build_name_suggestions_widget
2221from .widgets .profile_card_widget import build_profile_card_widget , profile_widget_copy_text
2322
7271
7372class CatAgentContext (AgentContext ):
7473 model_config = ConfigDict (arbitrary_types_allowed = True )
75- store : Annotated [MemoryStore , Field (exclude = True )]
7674 cats : Annotated [CatStore , Field (exclude = True )]
77- request_context : dict [str , Any ]
7875
7976
8077async def _get_state (ctx : RunContextWrapper [CatAgentContext ]) -> CatState :
Original file line number Diff line number Diff line change 7676
7777class MetroAgentContext (AgentContext ):
7878 model_config = ConfigDict (arbitrary_types_allowed = True )
79- store : Annotated [MemoryStore , Field (exclude = True )]
8079 metro : Annotated [MetroMapStore , Field (exclude = True )]
81- request_context : Annotated [RequestContext , Field (exclude = True )]
8280
8381
8482class MapResult (BaseModel ):
Original file line number Diff line number Diff line change 1818 AssistantMessageItem ,
1919 Attachment ,
2020 ClientEffectEvent ,
21- ClientToolCallItem ,
2221 HiddenContextItem ,
2322 ThreadItemDoneEvent ,
2423 ThreadItemReplacedEvent ,
Original file line number Diff line number Diff line change 4949
5050class EventFinderContext (AgentContext ):
5151 model_config = ConfigDict (arbitrary_types_allowed = True )
52- store : Annotated [MemoryStore , Field (exclude = True )]
5352 events : Annotated [EventStore , Field (exclude = True )]
54- request_context : Annotated [RequestContext , Field (exclude = True , default_factory = RequestContext )]
5553
5654
5755class EventKeywords (BaseModel ):
Original file line number Diff line number Diff line change 1717from ..agents .event_finder_agent import event_finder_agent
1818from ..agents .puzzle_agent import puzzle_agent
1919from ..data .article_store import ArticleMetadata , ArticleRecord , ArticleStore
20- from ..memory_store import MemoryStore
21- from ..request_context import RequestContext
2220from ..widgets .article_list_widget import build_article_list_widget
2321
2422logging .basicConfig (level = logging .INFO )
8482
8583class NewsAgentContext (AgentContext ):
8684 model_config = ConfigDict (arbitrary_types_allowed = True )
87- store : Annotated [MemoryStore , Field (exclude = True )]
8885 articles : Annotated [ArticleStore , Field (exclude = True )]
89- request_context : Annotated [RequestContext , Field (exclude = True )]
9086
9187
9288# -- Structured results for tool calls --------------------------------------
Original file line number Diff line number Diff line change 11from __future__ import annotations
22
3- from typing import Annotated
4-
53from agents import Agent
64from chatkit .agents import AgentContext
7- from pydantic import ConfigDict , Field
8-
9- from ..memory_store import MemoryStore
10- from ..request_context import RequestContext
5+ from pydantic import ConfigDict
116
127INSTRUCTIONS = """
138 You host Foxhollow's Coffee Break Puzzle Corner — a cheerful diversion for readers steeped
4742
4843class PuzzleAgentContext (AgentContext ):
4944 model_config = ConfigDict (arbitrary_types_allowed = True )
50- store : Annotated [MemoryStore , Field (exclude = True )]
51- request_context : Annotated [RequestContext , Field (exclude = True , default_factory = RequestContext )]
5245
5346
5447puzzle_agent = Agent [PuzzleAgentContext ](
You can’t perform that action at this time.
0 commit comments