Security advisory — Malicious litellm versions 1.82.7 and 1.82.8 were removed from PyPI (potential API key exfiltration). Uninstall them, rotate exposed credentials, and upgrade to a safe release (e.g. 1.82.9+). Run pip show litellm to verify. PyPI · README

Agents API

Agent, Task, and AgentExecutor public fields.

agenticx.core — Agent API

This page is the SDK surface in agenticx.core. Near / Studio chat uses AgentRuntime, not this executor. Source lives under agenticx/core/, not agenticx/agents/.

Diagram: AgentExecutor(llm_provider=).run(agent=, task=) returns a dict.

Agent

agenticx.core.agent.Agent (Pydantic). Common fields:

FieldTypeNotes
idstrUUID if omitted
name / role / goalstrRequired persona
backstory`str \None`Optional
organization_idstrDefault "default-org"
toolslistBound BaseTool instances
max_iterationsintDefault 25. There is no max_iter or verbose

Task

agenticx.core.task.Task:

FieldTypeNotes
idstrUUID if omitted
descriptionstrRequired
expected_outputstrWhat “done” looks like
agent_id`str \None`Optional assignment
contextdictExtra context
dependencieslist[str]Other task IDs

AgentExecutor

Construct with a provider. Pass the agent at run time.

python
1from agenticx import Agent, Task, AgentExecutor
2from agenticx.llms import OpenAIProvider
3from agenticx.tools import tool
4
5@tool
6def echo(text: str) -> str:
7 """Return the input text."""
8 return text
9
10agent = Agent(
11 name="Assistant",
12 role="Helper",
13 goal="Assist users",
14 tools=[echo],
15)
16task = Task(description="Say hello", expected_output="A short greeting")
17
18executor = AgentExecutor(
19 llm_provider=OpenAIProvider(model="gpt-4o"),
20 tools=[echo],
21 max_iterations=50,
22)
23result = executor.run(agent=agent, task=task)

__init__ also accepts prompt_manager, compaction_config, enable_context_compilation, execution_lane. It does not take agent=, llm=, memory=, or human_in_the_loop=.

run(agent, task, session_key=None) returns a dict. Concurrent calls with the same session_key serialize when an ExecutionLane is set.


Tool decorator

python
1from agenticx.tools import tool
2
3@tool
4def my_tool(param: str) -> str:
5 """One-line description.
6
7 Args:
8 param: What the argument is
9 """
10 return f"Processed: {param}"

See Tools and Agent runtime.