10xscale-agentflow-cli 0.3.2.7__tar.gz → 0.3.2.9__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/10xscale_agentflow_cli.egg-info/PKG-INFO +6 -1
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/10xscale_agentflow_cli.egg-info/SOURCES.txt +3 -7
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/10xscale_agentflow_cli.egg-info/requires.txt +6 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/PKG-INFO +6 -1
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/commands/eval.py +8 -8
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/commands/init.py +5 -2
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/commands/skills.py +10 -0
- 10xscale_agentflow_cli-0.3.2.9/agentflow_cli/cli/templates/dev/graph/agent.py +63 -0
- 10xscale_agentflow_cli-0.3.2.9/agentflow_cli/cli/templates/prod/graph/agent.py +50 -0
- 10xscale_agentflow_cli-0.3.2.9/agentflow_cli/cli/templates/skills/agent-skills/references/agents-and-tools.md +323 -0
- 10xscale_agentflow_cli-0.3.2.9/agentflow_cli/cli/templates/skills/agent-skills/references/architecture.md +90 -0
- 10xscale_agentflow_cli-0.3.2.9/agentflow_cli/cli/templates/skills/agent-skills/references/prebuilt-agents-and-tools.md +367 -0
- 10xscale_agentflow_cli-0.3.2.9/agentflow_cli/cli/templates/skills/agent-skills/references/state-graph.md +213 -0
- 10xscale_agentflow_cli-0.3.2.9/agentflow_cli/cli/templates/skills/claude/SKILL.md +83 -0
- 10xscale_agentflow_cli-0.3.2.9/agentflow_cli/cli/templates/skills/codex/SKILL.md +82 -0
- 10xscale_agentflow_cli-0.3.2.9/agentflow_cli/cli/templates/skills/copilot/agentflow.instructions.md +107 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/auth/permissions.py +9 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/config/settings.py +8 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/config/setup_middleware.py +100 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/graph/router.py +97 -2
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/graph/schemas/graph_schemas.py +96 -2
- 10xscale_agentflow_cli-0.3.2.9/plan.md +267 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/pyproject.toml +8 -1
- 10xscale_agentflow_cli-0.3.2.7/agentflow_cli/cli/templates/dev/graph/agent.py +0 -132
- 10xscale_agentflow_cli-0.3.2.7/agentflow_cli/cli/templates/prod/graph/agent.py +0 -45
- 10xscale_agentflow_cli-0.3.2.7/agentflow_cli/cli/templates/prod/graph/nodes/__init__.py +0 -5
- 10xscale_agentflow_cli-0.3.2.7/agentflow_cli/cli/templates/prod/graph/nodes/main_node.py +0 -27
- 10xscale_agentflow_cli-0.3.2.7/agentflow_cli/cli/templates/prod/graph/nodes/tool_node.py +0 -10
- 10xscale_agentflow_cli-0.3.2.7/agentflow_cli/cli/templates/prod/graph/utils/tool_decision.py +0 -30
- 10xscale_agentflow_cli-0.3.2.7/agentflow_cli/cli/templates/skills/agent-skills/SKILL.md +0 -108
- 10xscale_agentflow_cli-0.3.2.7/agentflow_cli/cli/templates/skills/agent-skills/references/agents-and-tools.md +0 -65
- 10xscale_agentflow_cli-0.3.2.7/agentflow_cli/cli/templates/skills/agent-skills/references/architecture.md +0 -53
- 10xscale_agentflow_cli-0.3.2.7/agentflow_cli/cli/templates/skills/agent-skills/references/prebuilt-agents-and-tools.md +0 -59
- 10xscale_agentflow_cli-0.3.2.7/agentflow_cli/cli/templates/skills/agent-skills/references/state-graph.md +0 -67
- 10xscale_agentflow_cli-0.3.2.7/agentflow_cli/cli/templates/skills/copilot/agentflow.instructions.md +0 -54
- 10xscale_agentflow_cli-0.3.2.7/graph/__init__.py +0 -0
- 10xscale_agentflow_cli-0.3.2.7/requirements.txt +0 -29
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/10xscale_agentflow_cli.egg-info/dependency_links.txt +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/10xscale_agentflow_cli.egg-info/entry_points.txt +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/10xscale_agentflow_cli.egg-info/not-zip-safe +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/10xscale_agentflow_cli.egg-info/top_level.txt +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/MANIFEST.in +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/README.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow.json +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/commands/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/commands/api.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/commands/build.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/commands/test.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/commands/version.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/constants.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/core/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/core/config.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/core/output.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/core/validation.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/exceptions.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/logger.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/main.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/defaults.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/dev/agentflow.json +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/dev/graph/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/prod/.pre-commot-config.yaml +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/prod/agentflow.json +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/prod/auth/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/prod/auth/agent_auth.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/prod/evals/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/prod/evals/user_simulator_eval.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/prod/evals/weather_agents_eval.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/prod/graph/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/prod/graph/state.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/prod/graph/thread_name_generator.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/prod/graph/tools/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/prod/graph/tools/weather_tool.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7/agentflow_cli/cli/templates/prod/graph/utils → 10xscale_agentflow_cli-0.3.2.9/agentflow_cli/cli/templates/prod/graph/validators}/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/prod/graph/validators/lifecyle.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/prod/graph/validators/manager.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/prod/graph/validators/validators.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7/agentflow_cli/cli/templates/prod/graph/validators → 10xscale_agentflow_cli-0.3.2.9/agentflow_cli/cli/templates/prod/tests}/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/prod/tests/conftest.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/prod/tests/test_agent_eval.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/prod/tests/test_catalog_tools.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/prod/tests/test_graph_nodes.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/api-client.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/api-configuration.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/api-settings-and-middleware.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/auth-and-authorization.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/callbacks-and-command.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/checkpointing-and-threads.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/cli-commands.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/client-auth-and-errors.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/client-messages-invoke-stream.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/client-threads-memory-files.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/context-id-background.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/dependency-injection.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/evaluation.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/id-and-thread-name-generators.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/media-and-files.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/memory-and-store.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/production-runtime.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/providers-and-adapters.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/publishers-and-runtime-protocols.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/rate-limiting.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/remote-tools.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/rest-api-and-errors.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/security-and-validators.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/state-and-messages.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/stream-emitter.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/streaming.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/testing-and-evaluation.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/templates/skills/agent-skills/references/unit-testing.md +0 -0
- {10xscale_agentflow_cli-0.3.2.7/agentflow_cli/cli/templates/prod/tests → 10xscale_agentflow_cli-0.3.2.9/agentflow_cli/src}/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7/agentflow_cli/src → 10xscale_agentflow_cli-0.3.2.9/agentflow_cli/src/app/core/auth}/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/auth/auth_backend.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/auth/authorization.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/auth/base_auth.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/auth/jwt_auth.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7/agentflow_cli/src/app/core/auth → 10xscale_agentflow_cli-0.3.2.9/agentflow_cli/src/app/core/config}/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/config/graph_config.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/config/media_settings.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/config/sentry_config.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/config/setup_logs.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/config/worker_middleware.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/exceptions/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/exceptions/general_exception.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/exceptions/handle_errors.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/exceptions/resources_exceptions.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/exceptions/user_exception.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/middleware/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/middleware/rate_limit/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/middleware/rate_limit/base.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/middleware/rate_limit/factory.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/middleware/rate_limit/memory.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/middleware/rate_limit/middleware.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/middleware/rate_limit/redis.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/middleware/request_limits.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/middleware/security_headers.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/utils/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/core/utils/log_sanitizer.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/loader.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/main.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/a2a.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/a2ui.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/checkpointer/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/checkpointer/router.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/checkpointer/schemas/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/checkpointer/schemas/checkpointer_schemas.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/checkpointer/services/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/checkpointer/services/checkpointer_service.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/graph/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/graph/schemas/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/graph/services/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/graph/services/graph_service.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/graph/services/multimodal_preprocessor.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/media/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/media/router.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/media/schemas.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/ping/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/ping/router.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/setup_router.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/store/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/store/router.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/store/schemas/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/store/schemas/store_schemas.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/store/services/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/routers/store/services/store_service.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7/agentflow_cli/src/app/core/config → 10xscale_agentflow_cli-0.3.2.9/agentflow_cli/src/app/tasks}/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/tasks/user_tasks.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/utils/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/utils/callable_helper.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/utils/media/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/utils/media/extractor.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/utils/media/pipeline.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/utils/parse_output.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/utils/response_helper.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/utils/schemas/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/utils/schemas/output_schemas.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/utils/schemas/user_schemas.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/utils/snowflake_id_generator.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/utils/swagger_helper.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/utils/thread_name_generator.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/src/app/worker.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7/agentflow_cli/src/app/tasks → 10xscale_agentflow_cli-0.3.2.9/graph}/__init__.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/graph/react.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/setup.cfg +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/tests/test_multimodal_sprint2_extraction.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/tests/test_sprint4_media_api.py +0 -0
- {10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/tests/test_utils_parse_and_callable.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: 10xscale-agentflow-cli
|
|
3
|
-
Version: 0.3.2.
|
|
3
|
+
Version: 0.3.2.9
|
|
4
4
|
Summary: CLI and API for 10xscale AgentFlow
|
|
5
5
|
Author-email: 10xscale <contact@10xscale.ai>
|
|
6
6
|
Maintainer-email: Shudipto Trafder <shudiptotrafder@gmail.com>
|
|
@@ -47,6 +47,11 @@ Provides-Extra: media
|
|
|
47
47
|
Requires-Dist: textxtract[docx,html,md,pdf,xml]>=0.2.0; extra == "media"
|
|
48
48
|
Provides-Extra: gcloud
|
|
49
49
|
Requires-Dist: google-cloud-logging; extra == "gcloud"
|
|
50
|
+
Provides-Extra: otel
|
|
51
|
+
Requires-Dist: opentelemetry-api>=1.20.0; extra == "otel"
|
|
52
|
+
Requires-Dist: opentelemetry-sdk>=1.20.0; extra == "otel"
|
|
53
|
+
Requires-Dist: opentelemetry-instrumentation-fastapi>=0.40b0; extra == "otel"
|
|
54
|
+
Requires-Dist: opentelemetry-exporter-otlp>=1.20.0; extra == "otel"
|
|
50
55
|
|
|
51
56
|
# AgentFlow CLI
|
|
52
57
|
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
MANIFEST.in
|
|
2
2
|
README.md
|
|
3
3
|
agentflow.json
|
|
4
|
+
plan.md
|
|
4
5
|
pyproject.toml
|
|
5
|
-
requirements.txt
|
|
6
6
|
10xscale_agentflow_cli.egg-info/PKG-INFO
|
|
7
7
|
10xscale_agentflow_cli.egg-info/SOURCES.txt
|
|
8
8
|
10xscale_agentflow_cli.egg-info/dependency_links.txt
|
|
@@ -44,13 +44,8 @@ agentflow_cli/cli/templates/prod/graph/__init__.py
|
|
|
44
44
|
agentflow_cli/cli/templates/prod/graph/agent.py
|
|
45
45
|
agentflow_cli/cli/templates/prod/graph/state.py
|
|
46
46
|
agentflow_cli/cli/templates/prod/graph/thread_name_generator.py
|
|
47
|
-
agentflow_cli/cli/templates/prod/graph/nodes/__init__.py
|
|
48
|
-
agentflow_cli/cli/templates/prod/graph/nodes/main_node.py
|
|
49
|
-
agentflow_cli/cli/templates/prod/graph/nodes/tool_node.py
|
|
50
47
|
agentflow_cli/cli/templates/prod/graph/tools/__init__.py
|
|
51
48
|
agentflow_cli/cli/templates/prod/graph/tools/weather_tool.py
|
|
52
|
-
agentflow_cli/cli/templates/prod/graph/utils/__init__.py
|
|
53
|
-
agentflow_cli/cli/templates/prod/graph/utils/tool_decision.py
|
|
54
49
|
agentflow_cli/cli/templates/prod/graph/validators/__init__.py
|
|
55
50
|
agentflow_cli/cli/templates/prod/graph/validators/lifecyle.py
|
|
56
51
|
agentflow_cli/cli/templates/prod/graph/validators/manager.py
|
|
@@ -60,7 +55,6 @@ agentflow_cli/cli/templates/prod/tests/conftest.py
|
|
|
60
55
|
agentflow_cli/cli/templates/prod/tests/test_agent_eval.py
|
|
61
56
|
agentflow_cli/cli/templates/prod/tests/test_catalog_tools.py
|
|
62
57
|
agentflow_cli/cli/templates/prod/tests/test_graph_nodes.py
|
|
63
|
-
agentflow_cli/cli/templates/skills/agent-skills/SKILL.md
|
|
64
58
|
agentflow_cli/cli/templates/skills/agent-skills/references/agents-and-tools.md
|
|
65
59
|
agentflow_cli/cli/templates/skills/agent-skills/references/api-client.md
|
|
66
60
|
agentflow_cli/cli/templates/skills/agent-skills/references/api-configuration.md
|
|
@@ -93,6 +87,8 @@ agentflow_cli/cli/templates/skills/agent-skills/references/stream-emitter.md
|
|
|
93
87
|
agentflow_cli/cli/templates/skills/agent-skills/references/streaming.md
|
|
94
88
|
agentflow_cli/cli/templates/skills/agent-skills/references/testing-and-evaluation.md
|
|
95
89
|
agentflow_cli/cli/templates/skills/agent-skills/references/unit-testing.md
|
|
90
|
+
agentflow_cli/cli/templates/skills/claude/SKILL.md
|
|
91
|
+
agentflow_cli/cli/templates/skills/codex/SKILL.md
|
|
96
92
|
agentflow_cli/cli/templates/skills/copilot/agentflow.instructions.md
|
|
97
93
|
agentflow_cli/src/__init__.py
|
|
98
94
|
agentflow_cli/src/app/__init__.py
|
|
@@ -23,6 +23,12 @@ PyJWT
|
|
|
23
23
|
[media]
|
|
24
24
|
textxtract[docx,html,md,pdf,xml]>=0.2.0
|
|
25
25
|
|
|
26
|
+
[otel]
|
|
27
|
+
opentelemetry-api>=1.20.0
|
|
28
|
+
opentelemetry-sdk>=1.20.0
|
|
29
|
+
opentelemetry-instrumentation-fastapi>=0.40b0
|
|
30
|
+
opentelemetry-exporter-otlp>=1.20.0
|
|
31
|
+
|
|
26
32
|
[redis]
|
|
27
33
|
redis>=5.0.7
|
|
28
34
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: 10xscale-agentflow-cli
|
|
3
|
-
Version: 0.3.2.
|
|
3
|
+
Version: 0.3.2.9
|
|
4
4
|
Summary: CLI and API for 10xscale AgentFlow
|
|
5
5
|
Author-email: 10xscale <contact@10xscale.ai>
|
|
6
6
|
Maintainer-email: Shudipto Trafder <shudiptotrafder@gmail.com>
|
|
@@ -47,6 +47,11 @@ Provides-Extra: media
|
|
|
47
47
|
Requires-Dist: textxtract[docx,html,md,pdf,xml]>=0.2.0; extra == "media"
|
|
48
48
|
Provides-Extra: gcloud
|
|
49
49
|
Requires-Dist: google-cloud-logging; extra == "gcloud"
|
|
50
|
+
Provides-Extra: otel
|
|
51
|
+
Requires-Dist: opentelemetry-api>=1.20.0; extra == "otel"
|
|
52
|
+
Requires-Dist: opentelemetry-sdk>=1.20.0; extra == "otel"
|
|
53
|
+
Requires-Dist: opentelemetry-instrumentation-fastapi>=0.40b0; extra == "otel"
|
|
54
|
+
Requires-Dist: opentelemetry-exporter-otlp>=1.20.0; extra == "otel"
|
|
50
55
|
|
|
51
56
|
# AgentFlow CLI
|
|
52
57
|
|
{10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/commands/eval.py
RENAMED
|
@@ -14,7 +14,7 @@ from dataclasses import dataclass
|
|
|
14
14
|
from pathlib import Path
|
|
15
15
|
from typing import TYPE_CHECKING, Any
|
|
16
16
|
|
|
17
|
-
from agentflow.qa.evaluation import CriterionConfig, EvalConfig
|
|
17
|
+
from agentflow.qa.evaluation import CriteriaConfig, CriterionConfig, EvalConfig
|
|
18
18
|
from agentflow.qa.evaluation.collectors.trajectory_collector import (
|
|
19
19
|
TrajectoryCollector,
|
|
20
20
|
make_trajectory_callback,
|
|
@@ -135,13 +135,13 @@ class EvalCommand(BaseCommand):
|
|
|
135
135
|
|
|
136
136
|
def _default_config(self) -> EvalConfig:
|
|
137
137
|
return EvalConfig(
|
|
138
|
-
criteria=
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
),
|
|
143
|
-
|
|
144
|
-
|
|
138
|
+
criteria=CriteriaConfig(
|
|
139
|
+
tool_name_match=CriterionConfig.tool_name_match(threshold=1.0),
|
|
140
|
+
# response_match=CriterionConfig.response_match(threshold=0.8),
|
|
141
|
+
# hallucinations=CriterionConfig.hallucination(threshold=0.8),
|
|
142
|
+
rouge_match=CriterionConfig.rouge_match(threshold=0.5),
|
|
143
|
+
node_order=CriterionConfig.node_order(threshold=0.8),
|
|
144
|
+
)
|
|
145
145
|
)
|
|
146
146
|
|
|
147
147
|
# ------------------------------------------------------------------
|
{10xscale_agentflow_cli-0.3.2.7 → 10xscale_agentflow_cli-0.3.2.9}/agentflow_cli/cli/commands/init.py
RENAMED
|
@@ -152,6 +152,9 @@ class InitCommand(BaseCommand):
|
|
|
152
152
|
return None
|
|
153
153
|
context["auth"] = auth_choice.lower()
|
|
154
154
|
|
|
155
|
+
if context["auth"] == "none":
|
|
156
|
+
return context
|
|
157
|
+
|
|
155
158
|
rl_choice = questionary.select(
|
|
156
159
|
"Rate limiting?",
|
|
157
160
|
choices=["None", "Memory Based", "Redis Based"],
|
|
@@ -169,7 +172,7 @@ class InitCommand(BaseCommand):
|
|
|
169
172
|
rl_requests = questionary.text(
|
|
170
173
|
"Max requests per window?",
|
|
171
174
|
default="100",
|
|
172
|
-
validate=lambda v: v.isdigit() and int(v) > 0 or "Enter a positive integer",
|
|
175
|
+
validate=lambda v: (v.isdigit() and int(v) > 0) or "Enter a positive integer",
|
|
173
176
|
).ask()
|
|
174
177
|
if rl_requests is None:
|
|
175
178
|
return None
|
|
@@ -178,7 +181,7 @@ class InitCommand(BaseCommand):
|
|
|
178
181
|
rl_window = questionary.text(
|
|
179
182
|
"Window size (seconds)?",
|
|
180
183
|
default="60",
|
|
181
|
-
validate=lambda v: v.isdigit() and int(v) > 0 or "Enter a positive integer",
|
|
184
|
+
validate=lambda v: (v.isdigit() and int(v) > 0) or "Enter a positive integer",
|
|
182
185
|
).ask()
|
|
183
186
|
if rl_window is None:
|
|
184
187
|
return None
|
|
@@ -55,6 +55,11 @@ _TARGETS: tuple[_AgentTarget, ...] = (
|
|
|
55
55
|
source_relpath="agent-skills",
|
|
56
56
|
manifest=True,
|
|
57
57
|
),
|
|
58
|
+
_InstallArtifact(
|
|
59
|
+
kind="file",
|
|
60
|
+
install_relpath=".agents/skills/agentflow/SKILL.md",
|
|
61
|
+
source_relpath="codex/SKILL.md",
|
|
62
|
+
),
|
|
58
63
|
),
|
|
59
64
|
),
|
|
60
65
|
_AgentTarget(
|
|
@@ -66,6 +71,11 @@ _TARGETS: tuple[_AgentTarget, ...] = (
|
|
|
66
71
|
source_relpath="agent-skills",
|
|
67
72
|
manifest=True,
|
|
68
73
|
),
|
|
74
|
+
_InstallArtifact(
|
|
75
|
+
kind="file",
|
|
76
|
+
install_relpath=".claude/skills/agentflow/SKILL.md",
|
|
77
|
+
source_relpath="claude/SKILL.md",
|
|
78
|
+
),
|
|
69
79
|
),
|
|
70
80
|
),
|
|
71
81
|
_AgentTarget(
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import logging
|
|
2
|
+
from datetime import datetime
|
|
3
|
+
|
|
4
|
+
from agentflow.core.state import AgentState, StreamEmitter
|
|
5
|
+
from agentflow.prebuilt.agent import ReactAgent
|
|
6
|
+
from agentflow.storage.checkpointer import InMemoryCheckpointer
|
|
7
|
+
from dotenv import load_dotenv
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
load_dotenv()
|
|
11
|
+
|
|
12
|
+
checkpointer = InMemoryCheckpointer()
|
|
13
|
+
|
|
14
|
+
logger = logging.getLogger(__name__)
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
def call_weather_api(location: str) -> str:
|
|
18
|
+
return f"The weather in {location} is sunny"
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
def get_weather(
|
|
22
|
+
location: str,
|
|
23
|
+
tool_call_id: str | None = None,
|
|
24
|
+
state: AgentState | None = None,
|
|
25
|
+
emit: StreamEmitter | None = None,
|
|
26
|
+
) -> str:
|
|
27
|
+
"""Get the current weather for a specific location."""
|
|
28
|
+
if tool_call_id:
|
|
29
|
+
logger.info(f"Tool call ID: {tool_call_id}")
|
|
30
|
+
if state and hasattr(state, "context"):
|
|
31
|
+
logger.info(f"Number of messages in context: {len(state.context)}") # type: ignore
|
|
32
|
+
|
|
33
|
+
if emit:
|
|
34
|
+
emit.progress(f"Fetching weather for {location}")
|
|
35
|
+
|
|
36
|
+
return call_weather_api(location)
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
react_agent = ReactAgent(
|
|
40
|
+
model="google/gemini-2.5-flash",
|
|
41
|
+
provider="google",
|
|
42
|
+
system_prompt=[
|
|
43
|
+
{
|
|
44
|
+
"role": "system",
|
|
45
|
+
"content": """
|
|
46
|
+
You are a helpful assistant.
|
|
47
|
+
Your task is to assist the user in finding information and answering questions.
|
|
48
|
+
Use tools when they help answer the user.
|
|
49
|
+
""",
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
"role": "user",
|
|
53
|
+
"content": f"Today Date is {datetime.now().strftime('%Y-%m-%d')}",
|
|
54
|
+
}, # Inject current date into system prompt
|
|
55
|
+
],
|
|
56
|
+
trim_context=True,
|
|
57
|
+
tools=[get_weather],
|
|
58
|
+
)
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
app = react_agent.compile(
|
|
62
|
+
checkpointer=checkpointer,
|
|
63
|
+
)
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
from datetime import datetime
|
|
2
|
+
|
|
3
|
+
from agentflow.core.state import MessageContextManager
|
|
4
|
+
from agentflow.prebuilt.agent import ReactAgent
|
|
5
|
+
from agentflow.storage.checkpointer import InMemoryCheckpointer
|
|
6
|
+
from dotenv import load_dotenv
|
|
7
|
+
|
|
8
|
+
from graph.state import WeatherState
|
|
9
|
+
from graph.tools.weather_tool import get_weather
|
|
10
|
+
from graph.validators.manager import callback_manager
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
load_dotenv()
|
|
14
|
+
|
|
15
|
+
checkpointer = InMemoryCheckpointer()
|
|
16
|
+
|
|
17
|
+
context_manager = MessageContextManager(
|
|
18
|
+
max_messages=20, # last 20 user messages will be kept in context
|
|
19
|
+
remove_tool_msgs=True,
|
|
20
|
+
)
|
|
21
|
+
|
|
22
|
+
react_agent = ReactAgent(
|
|
23
|
+
state=WeatherState(),
|
|
24
|
+
model="google/gemini-2.5-flash",
|
|
25
|
+
provider="google",
|
|
26
|
+
system_prompt=[
|
|
27
|
+
{
|
|
28
|
+
"role": "system",
|
|
29
|
+
"content": """
|
|
30
|
+
You are a helpful assistant.
|
|
31
|
+
Your task is to assist the user in finding information and answering questions.
|
|
32
|
+
User Current Location: {user_location}
|
|
33
|
+
If missing information, ask the user for clarification.
|
|
34
|
+
Use tools when they help answer the user.
|
|
35
|
+
""",
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
"role": "user",
|
|
39
|
+
"content": f"Today Date is {datetime.now().strftime('%Y-%m-%d')}",
|
|
40
|
+
},
|
|
41
|
+
],
|
|
42
|
+
trim_context=True,
|
|
43
|
+
tools=[get_weather],
|
|
44
|
+
context_manager=context_manager,
|
|
45
|
+
)
|
|
46
|
+
|
|
47
|
+
app = react_agent.compile(
|
|
48
|
+
checkpointer=checkpointer,
|
|
49
|
+
callback_manager=callback_manager,
|
|
50
|
+
)
|
|
@@ -0,0 +1,323 @@
|
|
|
1
|
+
# Agents and Tools
|
|
2
|
+
|
|
3
|
+
Use this when adding model behavior, tools, tool routing, provider options, retries, fallbacks, memory, skills, or structured output to an agent.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## Agent
|
|
8
|
+
|
|
9
|
+
`Agent` is a graph node that calls an LLM provider and appends the response to state. It supports OpenAI, Google GenAI, and any OpenAI-compatible API behind a unified interface.
|
|
10
|
+
|
|
11
|
+
### Constructor reference
|
|
12
|
+
|
|
13
|
+
```python
|
|
14
|
+
Agent(
|
|
15
|
+
model: str, # required
|
|
16
|
+
output_type: str = "text", # "text" | "image" | "video" | "audio"
|
|
17
|
+
system_prompt: list[dict] | None = None,
|
|
18
|
+
tool_node: str | ToolNode | None = None,
|
|
19
|
+
extra_messages: list[Message] | None = None,
|
|
20
|
+
trim_context: bool = False,
|
|
21
|
+
tools_tags: set[str] | None = None,
|
|
22
|
+
reasoning_config: dict | bool | None = {"effort": "medium"},
|
|
23
|
+
skills: SkillConfig | None = None,
|
|
24
|
+
memory: MemoryConfig | None = None,
|
|
25
|
+
retry_config: RetryConfig | bool | None = True,
|
|
26
|
+
fallback_models: list[str | tuple[str, str]] | None = None,
|
|
27
|
+
multimodal_config: MultimodalConfig | None = None,
|
|
28
|
+
output_schema: type[BaseModel] | None = None,
|
|
29
|
+
# extra kwargs forwarded to provider SDK:
|
|
30
|
+
provider: str | None = None, # "openai" | "google"; auto-detected if omitted
|
|
31
|
+
base_url: str | None = None,
|
|
32
|
+
api_style: str = "chat", # "chat" | "responses" (OpenAI only)
|
|
33
|
+
use_vertex_ai: bool = False,
|
|
34
|
+
temperature: float | None = None,
|
|
35
|
+
max_tokens: int | None = None,
|
|
36
|
+
# ...any other provider kwargs
|
|
37
|
+
)
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
### Model and provider
|
|
41
|
+
|
|
42
|
+
Provider is auto-detected from the model name. Three ways to set it:
|
|
43
|
+
|
|
44
|
+
```python
|
|
45
|
+
agent = Agent(model="gpt-4o") # auto → openai
|
|
46
|
+
agent = Agent(model="gemini-2.5-flash") # auto → google
|
|
47
|
+
agent = Agent(model="openai/gpt-4o") # prefix syntax
|
|
48
|
+
agent = Agent(model="gpt-4o", provider="openai") # explicit kwarg
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
Third-party OpenAI-compatible APIs use `provider="openai"` + `base_url`:
|
|
52
|
+
|
|
53
|
+
```python
|
|
54
|
+
# Ollama (local)
|
|
55
|
+
Agent(model="llama3.2", provider="openai", base_url="http://localhost:11434/v1")
|
|
56
|
+
|
|
57
|
+
# DeepSeek
|
|
58
|
+
Agent(model="deepseek-chat", provider="openai", base_url="https://api.deepseek.com/v1")
|
|
59
|
+
|
|
60
|
+
# OpenRouter
|
|
61
|
+
Agent(model="anthropic/claude-3-5-sonnet", provider="openai", base_url="https://openrouter.ai/api/v1")
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
### System prompt
|
|
65
|
+
|
|
66
|
+
Pass a list of message dicts. `{field_name}` placeholders are replaced at runtime with values from `AgentState`:
|
|
67
|
+
|
|
68
|
+
```python
|
|
69
|
+
class MyState(AgentState):
|
|
70
|
+
user_name: str = "Guest"
|
|
71
|
+
language: str = "English"
|
|
72
|
+
|
|
73
|
+
agent = Agent(
|
|
74
|
+
model="gpt-4o",
|
|
75
|
+
system_prompt=[{"role": "system", "content": "Help {user_name}. Reply in {language}."}],
|
|
76
|
+
)
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
### Reasoning config
|
|
80
|
+
|
|
81
|
+
Reasoning is **on by default** at medium effort. Applies to both OpenAI and Google models.
|
|
82
|
+
|
|
83
|
+
```python
|
|
84
|
+
agent = Agent(model="gpt-4o") # on, medium effort
|
|
85
|
+
agent = Agent(model="gpt-4o", reasoning_config={"effort": "high"})
|
|
86
|
+
agent = Agent(model="gpt-4o", reasoning_config=None) # off
|
|
87
|
+
agent = Agent(model="o4-mini", reasoning_config={"effort": "low", "summary": "auto"}) # OpenAI
|
|
88
|
+
agent = Agent(model="gemini-2.5-flash", reasoning_config={"thinking_budget": 5000}) # Google exact
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
Google effort → thinking_budget mapping:
|
|
92
|
+
|
|
93
|
+
| `effort` | `thinking_budget` |
|
|
94
|
+
|---|---|
|
|
95
|
+
| `"low"` | 512 |
|
|
96
|
+
| `"medium"` (default) | 8192 |
|
|
97
|
+
| `"high"` | 24576 |
|
|
98
|
+
|
|
99
|
+
### Retry config
|
|
100
|
+
|
|
101
|
+
Default: 3 retries, 1 s initial delay, 2x back-off, 30 s cap. Retries on HTTP 429, 500, 502, 503, 529.
|
|
102
|
+
|
|
103
|
+
```python
|
|
104
|
+
from agentflow.core.graph.agent_internal.constants import RetryConfig
|
|
105
|
+
|
|
106
|
+
agent = Agent(model="gpt-4o", retry_config=False) # disable
|
|
107
|
+
|
|
108
|
+
agent = Agent(
|
|
109
|
+
model="gpt-4o",
|
|
110
|
+
retry_config=RetryConfig(max_retries=5, initial_delay=2.0, max_delay=60.0, backoff_factor=2.0),
|
|
111
|
+
)
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
`RetryConfig` fields: `max_retries` (3), `initial_delay` (1.0 s), `max_delay` (30.0 s), `backoff_factor` (2.0).
|
|
115
|
+
|
|
116
|
+
### Fallback models
|
|
117
|
+
|
|
118
|
+
When the primary model exhausts all retries, AgentFlow tries each fallback in order:
|
|
119
|
+
|
|
120
|
+
```python
|
|
121
|
+
agent = Agent(
|
|
122
|
+
model="gemini-2.5-flash",
|
|
123
|
+
provider="google",
|
|
124
|
+
fallback_models=[
|
|
125
|
+
"gemini-2.0-flash", # inherit provider
|
|
126
|
+
("gpt-4o-mini", "openai"), # explicit (model, provider) tuple
|
|
127
|
+
],
|
|
128
|
+
)
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
### Structured output
|
|
132
|
+
|
|
133
|
+
`output_schema` with a Pydantic model forces JSON output. Requires `output_type="text"` (default).
|
|
134
|
+
|
|
135
|
+
```python
|
|
136
|
+
from pydantic import BaseModel
|
|
137
|
+
|
|
138
|
+
class ReviewAnalysis(BaseModel):
|
|
139
|
+
sentiment: str
|
|
140
|
+
score: float
|
|
141
|
+
summary: str
|
|
142
|
+
|
|
143
|
+
agent = Agent(model="gpt-4o", output_schema=ReviewAnalysis)
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
### Extra messages
|
|
147
|
+
|
|
148
|
+
`extra_messages` are injected into every LLM call after the system prompt and before the context window. Use for few-shot examples or static instructions:
|
|
149
|
+
|
|
150
|
+
```python
|
|
151
|
+
agent = Agent(
|
|
152
|
+
model="gpt-4o",
|
|
153
|
+
extra_messages=[
|
|
154
|
+
Message.text_message("Q: What is 2+2?", role="user"),
|
|
155
|
+
Message.text_message("A: 4", role="assistant"),
|
|
156
|
+
],
|
|
157
|
+
)
|
|
158
|
+
```
|
|
159
|
+
|
|
160
|
+
### API style (OpenAI)
|
|
161
|
+
|
|
162
|
+
```python
|
|
163
|
+
agent = Agent(model="gpt-4o", api_style="chat") # default — Chat Completions
|
|
164
|
+
agent = Agent(model="o4-mini", api_style="responses") # Responses API
|
|
165
|
+
```
|
|
166
|
+
|
|
167
|
+
---
|
|
168
|
+
|
|
169
|
+
## ToolNode
|
|
170
|
+
|
|
171
|
+
`ToolNode` registers and executes callable tools. It supports local Python functions, MCP tools, Composio integrations, and dynamically added tools.
|
|
172
|
+
|
|
173
|
+
```python
|
|
174
|
+
from agentflow.core.graph import ToolNode
|
|
175
|
+
|
|
176
|
+
tool_node = ToolNode([get_weather, safe_calculator])
|
|
177
|
+
|
|
178
|
+
# Add a tool after creation
|
|
179
|
+
tool_node.add_tool(search_db)
|
|
180
|
+
```
|
|
181
|
+
|
|
182
|
+
### Tool authoring rules
|
|
183
|
+
|
|
184
|
+
- Docstring → model-facing tool description. Required for useful behavior.
|
|
185
|
+
- Type annotations → parameter schema. Required for correct tool calls.
|
|
186
|
+
- Return a plain value for a normal tool result.
|
|
187
|
+
- Return `ToolResult` to update state fields and return a message to the model.
|
|
188
|
+
- Keep model-visible parameters separate from injected parameters.
|
|
189
|
+
|
|
190
|
+
### Injectable parameters
|
|
191
|
+
|
|
192
|
+
These are invisible to the model schema — `ToolNode` injects them automatically:
|
|
193
|
+
|
|
194
|
+
| Parameter | Type | What is injected |
|
|
195
|
+
|---|---|---|
|
|
196
|
+
| `state` | `AgentState \| None` | Current graph state |
|
|
197
|
+
| `tool_call_id` | `str \| None` | ID of this specific tool call |
|
|
198
|
+
| `config` | `dict` | Execution config (`thread_id`, `user_id`, `run_id`, …) |
|
|
199
|
+
|
|
200
|
+
```python
|
|
201
|
+
def get_weather(
|
|
202
|
+
location: str, # from model
|
|
203
|
+
state: AgentState | None = None, # injected, hidden from schema
|
|
204
|
+
config: dict | None = None, # injected, hidden from schema
|
|
205
|
+
) -> str:
|
|
206
|
+
"""Get weather for a location."""
|
|
207
|
+
user = config.get("user_id", "anon") if config else "anon"
|
|
208
|
+
return f"Sunny in {location} (user: {user})"
|
|
209
|
+
```
|
|
210
|
+
|
|
211
|
+
### Returning state updates
|
|
212
|
+
|
|
213
|
+
Use `ToolResult` when a tool needs to update state fields and return a message:
|
|
214
|
+
|
|
215
|
+
```python
|
|
216
|
+
from agentflow.core.state.tool_result import ToolResult
|
|
217
|
+
|
|
218
|
+
class MyState(AgentState):
|
|
219
|
+
selected_city: str = ""
|
|
220
|
+
|
|
221
|
+
def select_city(city: str) -> ToolResult:
|
|
222
|
+
"""Set the currently selected city."""
|
|
223
|
+
return ToolResult(message=f"City set to '{city}'.", state={"selected_city": city})
|
|
224
|
+
```
|
|
225
|
+
|
|
226
|
+
### Filter tools by tag
|
|
227
|
+
|
|
228
|
+
`tools_tags` on `Agent` exposes only matching tools to the LLM:
|
|
229
|
+
|
|
230
|
+
```python
|
|
231
|
+
@tool(tags=["safe"])
|
|
232
|
+
def safe_search(query: str) -> str: ...
|
|
233
|
+
|
|
234
|
+
@tool(tags=["admin"])
|
|
235
|
+
def admin_action(cmd: str) -> str: ...
|
|
236
|
+
|
|
237
|
+
tool_node = ToolNode([safe_search, admin_action])
|
|
238
|
+
agent = Agent(model="gpt-4o", tool_node=tool_node, tools_tags={"safe"})
|
|
239
|
+
# admin_action is hidden from this agent's model schema
|
|
240
|
+
```
|
|
241
|
+
|
|
242
|
+
### MCP tools
|
|
243
|
+
|
|
244
|
+
```bash
|
|
245
|
+
pip install "10xscale-agentflow[mcp]"
|
|
246
|
+
```
|
|
247
|
+
|
|
248
|
+
```python
|
|
249
|
+
tool_node = ToolNode(
|
|
250
|
+
[local_fn],
|
|
251
|
+
client=mcp_client, # fastmcp Client
|
|
252
|
+
pass_user_info_to_mcp=True, # forward config["user"] to MCP context
|
|
253
|
+
)
|
|
254
|
+
```
|
|
255
|
+
|
|
256
|
+
---
|
|
257
|
+
|
|
258
|
+
## The `@tool` decorator
|
|
259
|
+
|
|
260
|
+
Attaches metadata to any function. Does not change injection behavior — enriches the model schema:
|
|
261
|
+
|
|
262
|
+
```python
|
|
263
|
+
from agentflow.utils import tool
|
|
264
|
+
|
|
265
|
+
@tool(
|
|
266
|
+
name="web_search",
|
|
267
|
+
description="Search the web for up-to-date information.",
|
|
268
|
+
tags=["search", "web"],
|
|
269
|
+
provider="custom",
|
|
270
|
+
capabilities=["network_access"],
|
|
271
|
+
metadata={"rate_limit": 100},
|
|
272
|
+
)
|
|
273
|
+
async def search_web(query: str, max_results: int = 5) -> list[str]:
|
|
274
|
+
"""Search the web."""
|
|
275
|
+
...
|
|
276
|
+
```
|
|
277
|
+
|
|
278
|
+
Without arguments: function name and docstring are used as defaults.
|
|
279
|
+
|
|
280
|
+
---
|
|
281
|
+
|
|
282
|
+
## ReAct loop
|
|
283
|
+
|
|
284
|
+
Standard routing pattern. The routing function inspects the last message:
|
|
285
|
+
|
|
286
|
+
```python
|
|
287
|
+
from agentflow.utils import END
|
|
288
|
+
|
|
289
|
+
def route(state: AgentState) -> str:
|
|
290
|
+
if not state.context:
|
|
291
|
+
return END
|
|
292
|
+
last = state.context[-1]
|
|
293
|
+
if hasattr(last, "tools_calls") and last.tools_calls and last.role == "assistant":
|
|
294
|
+
return "TOOL"
|
|
295
|
+
if last.role == "tool":
|
|
296
|
+
return "MAIN"
|
|
297
|
+
return END
|
|
298
|
+
|
|
299
|
+
graph.add_conditional_edges("MAIN", route, {"TOOL": "TOOL", END: END})
|
|
300
|
+
graph.add_edge("TOOL", "MAIN")
|
|
301
|
+
```
|
|
302
|
+
|
|
303
|
+
### Passing tool_node by name
|
|
304
|
+
|
|
305
|
+
Pass a string to share one `ToolNode` across multiple agents:
|
|
306
|
+
|
|
307
|
+
```python
|
|
308
|
+
agent = Agent(model="gpt-4o", tool_node="TOOL")
|
|
309
|
+
graph.add_node("MAIN", agent)
|
|
310
|
+
graph.add_node("TOOL", tool_node)
|
|
311
|
+
```
|
|
312
|
+
|
|
313
|
+
---
|
|
314
|
+
|
|
315
|
+
## Source map
|
|
316
|
+
|
|
317
|
+
- Agent: https://github.com/10xHub/Agentflow/blob/main/agentflow/agentflow/core/graph/agent.py
|
|
318
|
+
- ToolNode: https://github.com/10xHub/Agentflow/tree/main/agentflow/agentflow/core/graph
|
|
319
|
+
- ToolResult: https://github.com/10xHub/Agentflow/blob/main/agentflow/agentflow/core/state/tool_result.py
|
|
320
|
+
- RetryConfig: https://github.com/10xHub/Agentflow/blob/main/agentflow/agentflow/core/graph/agent_internal/constants.py
|
|
321
|
+
- `@tool` decorator: https://github.com/10xHub/Agentflow/blob/main/agentflow/agentflow/utils/decorators.py
|
|
322
|
+
- Skills: https://github.com/10xHub/Agentflow/tree/main/agentflow/agentflow/core/skills
|
|
323
|
+
- How-to (configure Agent): https://agentflow.10xscale.ai/how-to/python/configure-agent
|