Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/JoshuaC215/agent-service-toolkit
/ functions
Functions
316 in github.com/JoshuaC215/agent-service-toolkit
⨍
Functions
316
◇
Types & classes
60
↳
Endpoints
8
↓ 19 callers
Function
get_model
(model_name: AllModelEnum, /)
src/core/llm.py:67
↓ 11 callers
Method
ainvoke
(self, messages: list[AnyMessage])
src/agents/safeguard.py:118
↓ 11 callers
Function
langchain_to_chat_message
Create a ChatMessage from a LangChain message.
src/service/utils.py:27
↓ 10 callers
Method
from_env
Create STT from environment variables. Reads VOICE_STT_PROVIDER env var to determine which provider to use. Returns None if not confi
src/voice/stt.py:116
↓ 9 callers
Function
get_agent
Get an agent graph, loading lazy agents if needed.
src/agents/agents.py:74
↓ 9 callers
Method
stream
Stream the agent's response synchronously. Each intermediate message of the agent process is yielded as a ChatMessage. If st
src/client/client.py:202
↓ 8 callers
Method
to_logging_level
Convert to Python logging level constant.
src/core/settings.py:47
↓ 7 callers
Method
ainvoke
Invoke the agent asynchronously. Only the final message is returned. Args: message (str): The message to send to the age
src/client/client.py:86
↓ 7 callers
Method
invoke
Invoke the agent synchronously. Only the final message is returned. Args: message (str): The message to send to the agen
src/client/client.py:132
↓ 6 callers
Method
get_graph
Get the agent's graph. Returns the graph instance that was created during load(). Returns: The agent's graph (C
src/agents/lazy_agent.py:30
↓ 5 callers
Function
_create_ai_message
(parts: dict)
src/service/service.py:336
↓ 5 callers
Method
astream
Stream the agent's response asynchronously. Each intermediate message of the agent process is yielded as an AnyMessage. If s
src/client/client.py:259
↓ 5 callers
Method
pretty_print
(self)
src/schema/schema.py:135
↓ 4 callers
Function
amessage_iter
()
tests/app/test_streamlit_app.py:122
↓ 4 callers
Function
check_str_is_http
(x: str)
src/core/settings.py:61
↓ 4 callers
Function
convert_message_content_to_string
(content: str | list[str | dict])
src/service/utils.py:14
↓ 4 callers
Function
load_agent
Load lazy agents if needed.
src/agents/agents.py:67
↓ 4 callers
Method
setup
(self)
src/memory/sqlite.py:27
↓ 4 callers
Method
to_langchain
(self)
src/agents/utils.py:13
↓ 4 callers
Method
transcribe
Transcribe audio using OpenAI Whisper. Args: audio_file: Binary audio file Returns: Transcribed text (empty
src/voice/providers/openai_stt.py:27
↓ 4 callers
Method
update_agent
(self, agent: str, verify: bool = True)
src/client/client.py:75
↓ 3 callers
Method
_create_graph
Create the GitHub MCP agent graph.
src/agents/github_mcp_agent/github_mcp_agent.py:89
↓ 3 callers
Method
_generate_and_dispatch_message
(self, writer: StreamWriter | None, data: dict)
src/agents/bg_task_agent/task.py:19
↓ 3 callers
Method
_validate_and_prepare_text
Validate and prepare text for TTS generation. Args: text: Raw text input Returns: Prepared text ready for TT
src/voice/providers/openai_tts.py:48
↓ 3 callers
Method
acreate_feedback
Create a feedback record for a run. This is a simple wrapper for the LangSmith create_feedback API, so the credentials can b
src/client/client.py:319
↓ 3 callers
Method
get_history
Get chat history. Args: thread_id (str, optional): Thread ID for identifying a conversation
src/client/client.py:343
↓ 3 callers
Method
is_dev
(self)
src/core/settings.py:254
↓ 3 callers
Method
load
Initialize the GitHub MCP agent by loading MCP tools.
src/agents/github_mcp_agent/github_mcp_agent.py:51
↓ 3 callers
Method
retrieve_info
(self)
src/client/client.py:60
↓ 3 callers
Function
wrap_model
( model: BaseChatModel | Runnable[LanguageModelInput, Any], system_prompt: BaseMessage )
src/agents/interrupt_agent.py:30
↓ 2 callers
Method
_compile_messages
(self, messages: list[AnyMessage])
src/agents/safeguard.py:101
↓ 2 callers
Function
_handle_input
Parse user input and handle any required interrupt resumption. Returns kwargs for agent invocation and the run_id.
src/service/service.py:125
↓ 2 callers
Function
_has_auth_credentials
()
src/memory/mongodb.py:14
↓ 2 callers
Method
_parse_stream_line
(self, line: str)
src/client/client.py:177
↓ 2 callers
Method
_transcribe_audio
Transcribe audio with UI feedback. Shows spinner during transcription and error message on failure. Args: audio: Audio f
src/voice/manager.py:79
↓ 2 callers
Method
bind_tools
(self, tools)
src/core/llm.py:49
↓ 2 callers
Method
dispatch
(self, writer: StreamWriter)
src/agents/utils.py:16
↓ 2 callers
Function
draw_messages
Draws a set of chat messages - either replaying existing messages or streaming new ones. This function has additional logic to handle st
src/streamlit_app.py:306
↓ 2 callers
Method
finish
( self, result: Literal["success", "error"], writer: StreamWriter | None = None,
src/agents/bg_task_agent/task.py:44
↓ 2 callers
Method
generate
Generate speech from text. Args: text: Text to convert to speech Returns: MP3 audio bytes, or None if text i
src/voice/providers/openai_tts.py:79
↓ 2 callers
Function
get_all_agent_info
()
src/agents/agents.py:88
↓ 2 callers
Method
get_format
Get audio format (MIME type) for this provider. Returns: MIME type string (e.g., "audio/mp3")
src/voice/tts.py:168
↓ 2 callers
Function
get_postgres_connection_string
Build and return the PostgreSQL connection string from settings.
src/memory/postgres.py:40
↓ 2 callers
Method
invoke
(self, messages: list[AnyMessage])
src/agents/safeguard.py:111
↓ 2 callers
Method
load
Perform async loading for this agent. This method is called during service startup and should handle: - Setting up external
src/agents/lazy_agent.py:18
↓ 2 callers
Function
message_generator
Generate a stream of messages from the agent. This is the workhorse method for the /stream endpoint.
src/service/service.py:223
↓ 2 callers
Function
parse_safeguard_output
(output: str)
src/agents/safeguard.py:68
↓ 2 callers
Method
render_message
Render message with optional TTS audio. Handles Streamlit UI including text display and audio player. Saves generated audio in sessio
src/voice/manager.py:158
↓ 2 callers
Method
start
(self, writer: StreamWriter | None = None, data: dict = {})
src/agents/bg_task_agent/task.py:32
↓ 2 callers
Function
validate_postgres_config
Validate that all required PostgreSQL configuration is present. Raises ValueError if any required configuration is missing.
src/memory/postgres.py:14
↓ 2 callers
Function
workflow
(chosen_model)
src/agents/langgraph_supervisor_hierarchy_agent.py:10
↓ 1 callers
Method
__aenter__
(self)
src/memory/sqlite.py:20
↓ 1 callers
Method
_get_api_key
Get API key from parameter or environment. Args: provider: Provider name api_key: API key from parameter (takes prece
src/voice/stt.py:52
↓ 1 callers
Method
_get_api_key
Get API key from parameter or environment. Args: provider: Provider name api_key: API key from parameter (takes prece
src/voice/tts.py:54
↓ 1 callers
Method
_load_provider
Load the appropriate STT provider implementation. Args: provider: Provider name api_key: Resolved API key
src/voice/stt.py:75
↓ 1 callers
Method
_load_provider
Load the appropriate TTS provider implementation. Args: provider: Provider name api_key: Resolved API key
src/voice/tts.py:77
↓ 1 callers
Method
add_and_draw_task_data
(self, task_data: TaskData)
src/schema/task_data.py:44
↓ 1 callers
Function
amain
()
src/run_client.py:8
↓ 1 callers
Function
amessage_iter
()
src/streamlit_app.py:227
↓ 1 callers
Function
architecture_dialog
()
src/streamlit_app.py:165
↓ 1 callers
Function
async_events
()
tests/client/test_client.py:191
↓ 1 callers
Method
completed
(self)
src/schema/task_data.py:30
↓ 1 callers
Method
completed_with_error
(self)
src/schema/task_data.py:33
↓ 1 callers
Function
create_chroma_db
( folder_path: str, db_name: str = "./chroma_db", delete_chroma_db: bool = True, chunk_size: i
scripts/create_chroma_db.py:14
↓ 1 callers
Function
format_contexts
(docs)
src/agents/tools.py:46
↓ 1 callers
Function
format_safety_message
(safety: SafeguardOutput)
src/agents/research_assistant.py:63
↓ 1 callers
Function
format_safety_message
(safety: SafeguardOutput)
src/agents/rag_assistant.py:59
↓ 1 callers
Method
generate
Generate speech from text. Delegates to the underlying provider implementation. Args: text: Text to convert to speech
src/voice/tts.py:155
↓ 1 callers
Method
get_chat_input
Get chat input with optional voice transcription. Handles Streamlit UI including audio input widget and transcription feedback (spinn
src/voice/manager.py:106
↓ 1 callers
Function
get_kb_retriever
Create and return a Knowledge Base retriever instance.
src/agents/knowledge_base_agent.py:28
↓ 1 callers
Function
get_mongo_connection_string
Build and return the MongoDB connection string from settings.
src/memory/mongodb.py:40
↓ 1 callers
Function
get_mongo_saver
Initialize and return a MongoDB saver instance.
src/memory/mongodb.py:84
↓ 1 callers
Function
get_or_create_user_id
Get the user ID from session state or URL parameters, or create a new one if it doesn't exist.
src/streamlit_app.py:32
↓ 1 callers
Function
get_postgres_saver
Initialize and return a PostgreSQL saver instance based on a connection pool for more resilent connections.
src/memory/postgres.py:53
↓ 1 callers
Function
get_postgres_store
Get a PostgreSQL store instance based on a connection pool for more resilent connections. Returns an AsyncPostgresStore instance that can be
src/memory/postgres.py:77
↓ 1 callers
Function
get_sqlite_saver
Initialize and return a SQLite saver instance.
src/memory/sqlite.py:9
↓ 1 callers
Function
get_sqlite_store
Initialize and return a store instance for long-term memory. Note: SQLite-specific store isn't available in LangGraph, so we use InMemoryStor
src/memory/sqlite.py:33
↓ 1 callers
Function
handle_feedback
Draws a feedback widget and records feedback from the user.
src/streamlit_app.py:465
↓ 1 callers
Function
handle_sub_agent_msgs
This function segregates agent output into a status container. It handles all messages after the initial tool call message until it reach
src/streamlit_app.py:495
↓ 1 callers
Function
initialize_database
Initialize the appropriate database checkpointer based on configuration. Returns an initialized AsyncCheckpointer instance.
src/memory/__init__.py:13
↓ 1 callers
Function
initialize_store
Initialize the appropriate store based on configuration. Returns an async context manager for the initialized store.
src/memory/__init__.py:28
↓ 1 callers
Method
load
Test load implementation.
tests/agents/test_lazy_agent.py:16
↓ 1 callers
Function
load_chroma_db
()
src/agents/tools.py:50
↓ 1 callers
Function
main
()
src/run_client.py:30
↓ 1 callers
Function
main
()
src/run_agent.py:19
↓ 1 callers
Function
main
()
src/streamlit_app.py:56
↓ 1 callers
Method
pretty_repr
Get a pretty representation of the message.
src/schema/schema.py:125
↓ 1 callers
Function
remove_tool_calls
Remove tool calls from content.
src/service/utils.py:67
↓ 1 callers
Function
share_chat_dialog
()
src/streamlit_app.py:183
↓ 1 callers
Method
transcribe
Transcribe audio to text. Delegates to the underlying provider implementation. Args: audio_file: Binary audio file
src/voice/stt.py:147
↓ 1 callers
Function
validate_mongo_config
Validate that all required MongoDB configuration is present. Raises ValueError if any required configuration is missing.
src/memory/mongodb.py:24
↓ 1 callers
Function
wrap_model
(model: BaseChatModel)
src/agents/research_assistant.py:54
↓ 1 callers
Function
wrap_model
(model: BaseChatModel)
src/agents/rag_assistant.py:50
↓ 1 callers
Function
wrap_model
Wrap the model with a system prompt for the Knowledge Base agent.
src/agents/knowledge_base_agent.py:47
↓ 1 callers
Function
wrap_model
(model: BaseChatModel)
src/agents/bg_task_agent/bg_task_agent.py:20
↓ 1 callers
Method
write_data
(self, writer: StreamWriter | None = None, data: dict = {})
src/agents/bg_task_agent/task.py:37
Method
BASE_URL
(self)
src/core/settings.py:251
Method
__aenter__
(self)
src/memory/mongodb.py:71
Method
__aexit__
(self, exc_type, exc_val, exc_tb)
src/memory/mongodb.py:79
Method
__aexit__
(self, exc_type, exc_val, exc_tb)
src/memory/sqlite.py:23
next →
1–100 of 316, ranked by callers