DeepFabric 4.5.1__tar.gz → 4.6.0__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.
- {deepfabric-4.5.1 → deepfabric-4.6.0}/.github/workflows/integration.yml +25 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/.gitignore +4 -0
- deepfabric-4.6.0/Makefile +65 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/PKG-INFO +79 -175
- {deepfabric-4.5.1 → deepfabric-4.6.0}/README.md +76 -174
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/__init__.py +8 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/auth.py +8 -2
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/builders.py +2 -2
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/builders_agent.py +2 -2
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/cli.py +289 -10
- deepfabric-4.6.0/deepfabric/cloud_upload.py +884 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/config.py +47 -20
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/config_manager.py +2 -2
- deepfabric-4.6.0/deepfabric/dataset.py +302 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/evaluation/parser.py +8 -8
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/evaluation/reporters/cloud_reporter.py +19 -6
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/exceptions.py +14 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/generator.py +4 -4
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/graph.py +38 -0
- deepfabric-4.6.0/deepfabric/loader.py +554 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/schemas.py +5 -5
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/topic_manager.py +4 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/training/callback.py +43 -1
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/training/metrics_sender.py +50 -16
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/tui.py +9 -1
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/utils.py +14 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/validation.py +1 -1
- deepfabric-4.6.0/docs/cli/evaluate.md +64 -0
- deepfabric-4.6.0/docs/cli/generate.md +220 -0
- deepfabric-4.6.0/docs/cli/import-tools.md +347 -0
- deepfabric-4.6.0/docs/cli/index.md +136 -0
- deepfabric-4.6.0/docs/cli/info.md +37 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/docs/cli/upload-hf.md +35 -25
- {deepfabric-4.5.1 → deepfabric-4.6.0}/docs/cli/upload-kaggle.md +22 -18
- deepfabric-4.6.0/docs/cli/validate.md +154 -0
- deepfabric-4.6.0/docs/cli/visualize.md +147 -0
- deepfabric-4.6.0/docs/dataset-generation/agent.md +245 -0
- deepfabric-4.6.0/docs/dataset-generation/basic.md +132 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/docs/dataset-generation/configuration.md +21 -16
- deepfabric-4.6.0/docs/dataset-generation/index.md +120 -0
- deepfabric-4.6.0/docs/dataset-generation/rate-limiting.md +218 -0
- deepfabric-4.6.0/docs/dataset-generation/reasoning.md +107 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/docs/evaluation/index.md +44 -17
- {deepfabric-4.5.1 → deepfabric-4.6.0}/docs/evaluation/metrics.md +40 -37
- deepfabric-4.6.0/docs/evaluation/running.md +318 -0
- deepfabric-4.6.0/docs/images/python-spin.png +0 -0
- deepfabric-4.6.0/docs/index.md +246 -0
- deepfabric-4.6.0/docs/tools/custom.md +443 -0
- deepfabric-4.6.0/docs/tools/index.md +162 -0
- deepfabric-4.6.0/docs/tools/mock.md +385 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/docs/tools/spin.md +68 -60
- deepfabric-4.6.0/docs/tools/tutorials/go.md +557 -0
- deepfabric-4.6.0/docs/tools/tutorials/index.md +59 -0
- deepfabric-4.6.0/docs/tools/tutorials/python.md +446 -0
- deepfabric-4.6.0/docs/tools/tutorials/rust.md +562 -0
- deepfabric-4.6.0/docs/tools/tutorials/typescript.md +458 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/docs/tools/vfs.md +28 -51
- {deepfabric-4.5.1 → deepfabric-4.6.0}/docs/training/chat-templates.md +38 -37
- {deepfabric-4.5.1 → deepfabric-4.6.0}/docs/training/dataset-preparation.md +93 -53
- {deepfabric-4.5.1 → deepfabric-4.6.0}/docs/training/frameworks.md +48 -110
- deepfabric-4.6.0/docs/training/index.md +119 -0
- deepfabric-4.6.0/docs/training/loading.md +275 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/agent-tools-multi.yaml +1 -1
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/agent-tools-single.yaml +1 -1
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/basic-graph.yaml +3 -3
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/coding-agent.yaml +1 -1
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/complete.yaml +2 -2
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/github-mock-tools.yaml +1 -1
- deepfabric-4.6.0/examples/mcp-adversarial-suite/README.md +269 -0
- deepfabric-4.6.0/examples/mcp-adversarial-suite/configs/all.yaml +213 -0
- deepfabric-4.6.0/examples/mcp-adversarial-suite/configs/driftlab.yaml +113 -0
- deepfabric-4.6.0/examples/mcp-adversarial-suite/configs/homoglyph.yaml +107 -0
- deepfabric-4.6.0/examples/mcp-adversarial-suite/configs/insecurefs.yaml +139 -0
- deepfabric-4.6.0/examples/mcp-adversarial-suite/configs/resource_trap.yaml +147 -0
- deepfabric-4.6.0/examples/mcp-adversarial-suite/configs/spoofbox.yaml +124 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/reasoning.yaml +1 -1
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/spin-vfs-tools.yaml +1 -1
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/tools-sdk-examples/blender/spin-blender.yaml +1 -1
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/tools-sdk-examples/figma/spin-figma.yaml +1 -1
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/tools-sdk-examples/github/spin-github-tools.yaml +1 -1
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/tools-sdk-examples/kubernetes/spin-kubernetes.yaml +1 -1
- {deepfabric-4.5.1 → deepfabric-4.6.0}/mkdocs.yml +43 -22
- deepfabric-4.6.0/notebooks/ChatGPT Image Dec 27, 2025, 06_41_41 PM.png +0 -0
- deepfabric-4.6.0/notebooks/Train_and_Evaluate_Qwen3_4B_Thinking_as_a_Blender_MCP_Agent.ipynb +10442 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/notebooks/dataset-compatibility-check.ipynb +4 -4
- {deepfabric-4.5.1 → deepfabric-4.6.0}/pyproject.toml +7 -1
- deepfabric-4.6.0/tests/integration/conftest.py +42 -0
- deepfabric-4.6.0/tests/integration/test_generator_integration.py +160 -0
- deepfabric-4.6.0/tests/integration/test_graph_integration.py +150 -0
- deepfabric-4.6.0/tests/integration/test_llm_client_integration.py +141 -0
- deepfabric-4.6.0/tests/integration/test_spin_integration.py +149 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tests/integration/test_tree_integration.py +7 -5
- deepfabric-4.6.0/tests/unit/test_cloud_upload.py +359 -0
- deepfabric-4.6.0/tests/unit/test_dataset.py +345 -0
- deepfabric-4.6.0/tests/unit/test_loader.py +593 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tests/unit/test_modular_config.py +25 -25
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tests/unit/test_schemas.py +10 -10
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tests/unit/test_topic_graph.py +146 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tests/unit/test_training_callback.py +1 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools-sdk/components/github/README.md +1 -1
- {deepfabric-4.5.1 → deepfabric-4.6.0}/uv.lock +32 -1
- deepfabric-4.5.1/Makefile +0 -36
- deepfabric-4.5.1/docs/api/config.md +0 -325
- deepfabric-4.5.1/docs/api/generator.md +0 -458
- deepfabric-4.5.1/docs/api/graph.md +0 -327
- deepfabric-4.5.1/docs/api/index.md +0 -135
- deepfabric-4.5.1/docs/api/tree.md +0 -283
- deepfabric-4.5.1/docs/cli/format.md +0 -240
- deepfabric-4.5.1/docs/cli/generate.md +0 -165
- deepfabric-4.5.1/docs/cli/import-tools.md +0 -323
- deepfabric-4.5.1/docs/cli/index.md +0 -92
- deepfabric-4.5.1/docs/cli/validate.md +0 -144
- deepfabric-4.5.1/docs/cli/visualize.md +0 -115
- deepfabric-4.5.1/docs/dataset-generation/agent.md +0 -137
- deepfabric-4.5.1/docs/dataset-generation/basic.md +0 -92
- deepfabric-4.5.1/docs/dataset-generation/index.md +0 -60
- deepfabric-4.5.1/docs/dataset-generation/rate-limiting.md +0 -213
- deepfabric-4.5.1/docs/dataset-generation/reasoning.md +0 -99
- deepfabric-4.5.1/docs/evaluation/running.md +0 -300
- deepfabric-4.5.1/docs/getting-started/index.md +0 -98
- deepfabric-4.5.1/docs/index.md +0 -112
- deepfabric-4.5.1/docs/tools/custom.md +0 -223
- deepfabric-4.5.1/docs/tools/index.md +0 -91
- deepfabric-4.5.1/docs/tools/mcp.md +0 -165
- deepfabric-4.5.1/docs/tools/mock.md +0 -194
- deepfabric-4.5.1/docs/training/index.md +0 -69
- deepfabric-4.5.1/docs/training/loading.md +0 -143
- deepfabric-4.5.1/examples/tools-sdk-examples/blender/blender-mock-data.json +0 -915
- deepfabric-4.5.1/examples/tools-sdk-examples/figma/figma-mock-data.json +0 -586
- deepfabric-4.5.1/examples/tools-sdk-examples/github/github-mock-data.json +0 -542
- deepfabric-4.5.1/examples/tools-sdk-examples/kubernetes/kubernetes-mock-data.json +0 -1277
- deepfabric-4.5.1/examples/tools-sdk-examples/kubernetes/tools.json +0 -607
- {deepfabric-4.5.1 → deepfabric-4.6.0}/.github/config.yml +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/.github/dependabot.yml +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/.github/workflows/docs.yml +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/.github/workflows/publish.yml +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/.github/workflows/test.yml +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/.github/workflows/tools-sdk-docker.yml +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/CLAUDE.md +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/LICENSE +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/assets/df-demo.gif +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/assets/logo-light-hols.png +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/assets/logo-light.png +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/assets/star.gif +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/coverage.xml +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/__main__.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/constants.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/dataset_manager.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/error_codes.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/evaluation/__init__.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/evaluation/backends/__init__.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/evaluation/backends/llm_eval_backend.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/evaluation/backends/ollama_backend.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/evaluation/backends/tool_call_parsers.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/evaluation/backends/transformers_backend.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/evaluation/evaluator.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/evaluation/evaluators/__init__.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/evaluation/evaluators/base.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/evaluation/evaluators/builtin/__init__.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/evaluation/evaluators/builtin/tool_calling.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/evaluation/evaluators/registry.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/evaluation/inference.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/evaluation/metrics.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/evaluation/reporters/__init__.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/evaluation/reporters/base.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/evaluation/reporters/file_reporter.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/evaluation/reporters/multi_reporter.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/factory.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/hf_hub.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/kaggle_hub.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/llm/__init__.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/llm/api_key_verifier.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/llm/client.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/llm/errors.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/llm/rate_limit_config.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/llm/rate_limit_detector.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/llm/retry_handler.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/metrics.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/progress.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/prompts.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/spin/__init__.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/spin/client.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/spin/models.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/stream_simulator.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/tools/__init__.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/tools/defaults.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/tools/loader.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/tools/mcp_client.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/topic_model.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/training/__init__.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/training/api_key_prompt.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/training/dataset_utils.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/tree.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/deepfabric/update_checker.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/docs/images/logo-light.png +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/basic-anthropic.yaml +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/basic-gemini.yaml +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/basic-ollama.yaml +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/basic-openai.yaml +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/basic-openrouter.yaml +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/basic-tree.yaml +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/custom-tools.yaml +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/tools-sdk-examples/blender/load-blender-mock-data.sh +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/tools-sdk-examples/figma/load-figma-mock-data.sh +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/tools-sdk-examples/github/load-github-mock-data.sh +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/examples/tools-sdk-examples/kubernetes/load-kubernetes-mock-data.sh +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/misc/test_update_manual.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/notebooks/evaluations.ipynb +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/test-run/01-alpaca.txt +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/test-run/01-chatml.txt +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/test-run/01-grpo.txt +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/test-run/01-xlam_v2.txt +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/test-run/02-trl2.txt +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/test-run/02-xlam_v2.txt +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/test-run/04-agent-tool-conversations.jsnl +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/test-run/04-single-agent-tools +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tests/__init__.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tests/integration/__init__.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tests/unit/__init__.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tests/unit/conftest.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tests/unit/test_api_key_validation.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tests/unit/test_cli.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tests/unit/test_config.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tests/unit/test_error_codes.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tests/unit/test_gemini_schema.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tests/unit/test_generator.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tests/unit/test_hf_hub.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tests/unit/test_kaggle_hub.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tests/unit/test_llm_eval_backend.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tests/unit/test_rate_limiting.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tests/unit/test_tool_call_parsers.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tests/unit/test_update_checker.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools/extract_messages.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools/function.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools/yaml_to_openai_tools.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools-sdk/.dockerignore +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools-sdk/Dockerfile +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools-sdk/README.md +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools-sdk/components/github/app.py +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools-sdk/components/github/github.wasm +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools-sdk/components/github/pyproject.toml +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools-sdk/components/github/requirements.txt +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools-sdk/components/github/spin.toml +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools-sdk/components/github/uv.lock +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools-sdk/components/mock/Cargo.lock +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools-sdk/components/mock/Cargo.toml +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools-sdk/components/mock/README.md +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools-sdk/components/mock/src/lib.rs +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools-sdk/components/vfs/Cargo.lock +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools-sdk/components/vfs/Cargo.toml +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools-sdk/components/vfs/src/lib.rs +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools-sdk/docker-compose.yaml +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools-sdk/runtime-config.toml +0 -0
- {deepfabric-4.5.1 → deepfabric-4.6.0}/tools-sdk/spin.toml +0 -0
|
@@ -19,6 +19,12 @@ jobs:
|
|
|
19
19
|
name: Run integration tests (Python ${{ matrix.python-version }})
|
|
20
20
|
runs-on: ubuntu-latest
|
|
21
21
|
|
|
22
|
+
services:
|
|
23
|
+
spin:
|
|
24
|
+
image: ghcr.io/always-further/deepfabric/tools-sdk:latest
|
|
25
|
+
ports:
|
|
26
|
+
- 3000:3000
|
|
27
|
+
|
|
22
28
|
strategy:
|
|
23
29
|
fail-fast: false
|
|
24
30
|
matrix:
|
|
@@ -28,6 +34,23 @@ jobs:
|
|
|
28
34
|
- name: Checkout code
|
|
29
35
|
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v5
|
|
30
36
|
|
|
37
|
+
- name: Wait for Spin service
|
|
38
|
+
run: |
|
|
39
|
+
echo "Waiting for Spin service to be ready..."
|
|
40
|
+
for i in {1..30}; do
|
|
41
|
+
response=$(curl -s -o /dev/null -w "%{http_code}" http://localhost:3000/vfs/execute -X POST \
|
|
42
|
+
-H "Content-Type: application/json" \
|
|
43
|
+
-d '{"session_id":"healthcheck","tool":"list_files","args":{"directory":"/"}}' 2>/dev/null || echo "000")
|
|
44
|
+
if [ "$response" = "200" ]; then
|
|
45
|
+
echo "Spin service is ready"
|
|
46
|
+
exit 0
|
|
47
|
+
fi
|
|
48
|
+
echo "Attempt $i: waiting... (HTTP $response)"
|
|
49
|
+
sleep 2
|
|
50
|
+
done
|
|
51
|
+
echo "Spin service failed to become ready"
|
|
52
|
+
exit 1
|
|
53
|
+
|
|
31
54
|
- name: Set up Python
|
|
32
55
|
uses: actions/setup-python@83679a892e2d95755f2dac6acb0bfd1e9ac5d548 # v6
|
|
33
56
|
with:
|
|
@@ -46,3 +69,5 @@ jobs:
|
|
|
46
69
|
run: make test-integration
|
|
47
70
|
env:
|
|
48
71
|
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
|
|
72
|
+
GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }}
|
|
73
|
+
SPIN_ENDPOINT: http://localhost:3000
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
.PHONY: clean install format lint test-unit test-integration test-integration-verbose security build all
|
|
2
|
+
.PHONY: test-integration-openai test-integration-gemini test-integration-llm
|
|
3
|
+
.PHONY: test-integration-hubs test-integration-spin test-integration-quick
|
|
4
|
+
.PHONY: test-integration-graph test-integration-generator
|
|
5
|
+
|
|
6
|
+
# Base command for integration tests
|
|
7
|
+
PYTEST_INTEGRATION = uv run pytest tests/integration --tb=short -v
|
|
8
|
+
|
|
9
|
+
clean:
|
|
10
|
+
rm -rf build/
|
|
11
|
+
rm -rf dist/
|
|
12
|
+
rm -rf *.egg-info
|
|
13
|
+
rm -f .coverage
|
|
14
|
+
find . -type d -name '__pycache__' -exec rm -rf {} +
|
|
15
|
+
find . -type f -name '*.pyc' -delete
|
|
16
|
+
|
|
17
|
+
install:
|
|
18
|
+
uv sync --all-extras
|
|
19
|
+
|
|
20
|
+
format: ## Format code with ruff (parallel)
|
|
21
|
+
uv run ruff format deepfabric/ tests/
|
|
22
|
+
|
|
23
|
+
lint:
|
|
24
|
+
uv run ruff check . --exclude notebooks/
|
|
25
|
+
|
|
26
|
+
test-unit:
|
|
27
|
+
uv run pytest tests/unit/
|
|
28
|
+
|
|
29
|
+
test-integration:
|
|
30
|
+
$(PYTEST_INTEGRATION) --maxfail=1
|
|
31
|
+
|
|
32
|
+
test-integration-verbose:
|
|
33
|
+
uv run pytest tests/integration -v -rA --durations=10
|
|
34
|
+
|
|
35
|
+
test-integration-openai:
|
|
36
|
+
$(PYTEST_INTEGRATION) -m openai
|
|
37
|
+
|
|
38
|
+
test-integration-gemini:
|
|
39
|
+
$(PYTEST_INTEGRATION) -m gemini
|
|
40
|
+
|
|
41
|
+
test-integration-llm:
|
|
42
|
+
$(PYTEST_INTEGRATION) -m "openai or gemini"
|
|
43
|
+
|
|
44
|
+
test-integration-hubs:
|
|
45
|
+
$(PYTEST_INTEGRATION) -m huggingface
|
|
46
|
+
|
|
47
|
+
test-integration-spin:
|
|
48
|
+
$(PYTEST_INTEGRATION) -m spin
|
|
49
|
+
|
|
50
|
+
test-integration-quick:
|
|
51
|
+
$(PYTEST_INTEGRATION) -m "not huggingface"
|
|
52
|
+
|
|
53
|
+
test-integration-graph:
|
|
54
|
+
$(PYTEST_INTEGRATION) tests/integration/test_graph_integration.py
|
|
55
|
+
|
|
56
|
+
test-integration-generator:
|
|
57
|
+
$(PYTEST_INTEGRATION) tests/integration/test_generator_integration.py
|
|
58
|
+
|
|
59
|
+
security:
|
|
60
|
+
uv run bandit -r deepfabric/
|
|
61
|
+
|
|
62
|
+
build: clean test-unit
|
|
63
|
+
uv build
|
|
64
|
+
|
|
65
|
+
all: clean install format lint test-unit test-integration security build
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: DeepFabric
|
|
3
|
-
Version: 4.
|
|
3
|
+
Version: 4.6.0
|
|
4
4
|
Summary: Curate High Quality Datasets, Train, Evaluate and Ship
|
|
5
5
|
Author-email: Luke Hinds <luke@alwaysfurther.ai>
|
|
6
6
|
License-File: LICENSE
|
|
@@ -29,10 +29,12 @@ Requires-Dist: sentencepiece>=0.1.99
|
|
|
29
29
|
Requires-Dist: spin-sdk>=3.4.1
|
|
30
30
|
Requires-Dist: torch>=2.4.0
|
|
31
31
|
Requires-Dist: transformers>=4.57.1
|
|
32
|
+
Requires-Dist: trl>=0.26.2
|
|
32
33
|
Provides-Extra: dev
|
|
33
34
|
Requires-Dist: bandit>=1.7.10; extra == 'dev'
|
|
34
35
|
Requires-Dist: mermaid-py>=0.2.0; extra == 'dev'
|
|
35
36
|
Requires-Dist: pytest-cov>=4.0.0; extra == 'dev'
|
|
37
|
+
Requires-Dist: pytest-httpx>=0.30.0; extra == 'dev'
|
|
36
38
|
Requires-Dist: pytest-mock>=3.10.0; extra == 'dev'
|
|
37
39
|
Requires-Dist: pytest>=7.0.0; extra == 'dev'
|
|
38
40
|
Requires-Dist: requests-mock>=1.11.0; extra == 'dev'
|
|
@@ -45,7 +47,7 @@ Description-Content-Type: text/markdown
|
|
|
45
47
|
<div align="center">
|
|
46
48
|
<picture>
|
|
47
49
|
<source media="(prefers-color-scheme: dark)" srcset="./assets/logo-light.png" />
|
|
48
|
-
<img alt="DeepFabric logo" src="./assets/logo-light
|
|
50
|
+
<img alt="DeepFabric logo" src="./assets/logo-light.png" style="width:40%;max-width:40%;height:auto;display:block;margin:0 auto;" />
|
|
49
51
|
</picture>
|
|
50
52
|
<h3>Training Model Behavior in Agentic Systems</h3>
|
|
51
53
|
|
|
@@ -123,7 +125,15 @@ This generates a topic graph and creates 27 unique nodes, then generates 27 trai
|
|
|
123
125
|
|
|
124
126
|
## Configuration
|
|
125
127
|
|
|
126
|
-
DeepFabric also uses YAML configuration with three main sections and optional shared LLM defaults
|
|
128
|
+
DeepFabric also uses YAML configuration with three main sections and optional shared LLM defaults
|
|
129
|
+
|
|
130
|
+
> [!NOTE]
|
|
131
|
+
> The following uses mocked tool execution, so will require a runing Spin service, which we provide in a docker image:
|
|
132
|
+
```bash
|
|
133
|
+
docker run -d -p 3000:3000 ghcr.io/always-further/deepfabric/tools-sdk:latest`
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
Save the following as `config.yaml`:
|
|
127
137
|
|
|
128
138
|
```yaml
|
|
129
139
|
# Optional: Shared LLM defaults (inherited by topics and generation)
|
|
@@ -146,34 +156,74 @@ topics:
|
|
|
146
156
|
# GENERATION: Create training samples from topics
|
|
147
157
|
generation:
|
|
148
158
|
system_prompt: |
|
|
149
|
-
You are an expert Python backend developer
|
|
159
|
+
You are an expert Python backend developer specializing in REST API design.
|
|
150
160
|
Create practical, production-ready code examples with clear explanations.
|
|
151
161
|
Include error handling, type hints, and follow PEP 8 conventions.
|
|
162
|
+
Use the following tools to read, write, and list files in the virtual filesystem:
|
|
163
|
+
- read_file
|
|
164
|
+
- write_file
|
|
165
|
+
- list_files
|
|
152
166
|
|
|
153
167
|
# Additional instructions for sample generation
|
|
154
168
|
instructions: |
|
|
155
|
-
Focus on real-world scenarios developers encounter daily.
|
|
169
|
+
Focus on real-world scenarios developers encounter daily when building REST APIs with Python.
|
|
156
170
|
Include both happy path and edge case handling.
|
|
157
|
-
Provide context on when and why to use specific patterns.
|
|
171
|
+
Provide context on when and why to use specific patterns or libraries.
|
|
172
|
+
Ensure code is modular, testable, and maintainable.
|
|
158
173
|
|
|
159
174
|
conversation:
|
|
160
|
-
type:
|
|
161
|
-
reasoning_style: agent # freetext | agent (for
|
|
175
|
+
type: cot # basic | cot
|
|
176
|
+
reasoning_style: agent # freetext | agent (for cot)
|
|
162
177
|
agent_mode: single_turn # single_turn | multi_turn (for agent)
|
|
163
178
|
|
|
164
179
|
# Tool configuration (required for agent modes)
|
|
165
180
|
tools:
|
|
166
181
|
spin_endpoint: "http://localhost:3000" # Spin service for tool execution
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
182
|
+
components: # Map component name to tool names
|
|
183
|
+
builtin: # Routes to /vfs/execute
|
|
184
|
+
- read_file
|
|
185
|
+
- write_file
|
|
186
|
+
- list_files
|
|
171
187
|
max_per_query: 3 # Maximum tools per query
|
|
172
188
|
max_agent_steps: 5 # Max ReAct reasoning iterations
|
|
173
189
|
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
190
|
+
# Optional: Seed initial files into the spin before generation, used for tool calling
|
|
191
|
+
scenario_seed:
|
|
192
|
+
files:
|
|
193
|
+
"Dockerfile": |
|
|
194
|
+
FROM python:3.13
|
|
195
|
+
WORKDIR /usr/local/app
|
|
196
|
+
|
|
197
|
+
# Install the application dependencies
|
|
198
|
+
COPY requirements.txt ./
|
|
199
|
+
RUN pip install --no-cache-dir -r requirements.txt
|
|
200
|
+
|
|
201
|
+
# Copy in the source code
|
|
202
|
+
COPY src ./src
|
|
203
|
+
EXPOSE 8080
|
|
204
|
+
|
|
205
|
+
# Setup an app user so the container doesn't run as the root user
|
|
206
|
+
RUN useradd app
|
|
207
|
+
USER app
|
|
208
|
+
|
|
209
|
+
CMD ["uvicorn", "app.main:app", "--host", "0.0.0.0", "--port", "8080"]
|
|
210
|
+
"main.py": |
|
|
211
|
+
def greet(name):
|
|
212
|
+
return f"Hello, {name}!"
|
|
213
|
+
|
|
214
|
+
if __name__ == "__main__":
|
|
215
|
+
print(greet("World"))
|
|
216
|
+
"config.json": |
|
|
217
|
+
{
|
|
218
|
+
"version": "1.0.0",
|
|
219
|
+
"debug": true,
|
|
220
|
+
"max_retries": 3
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
# Generation control and retry settings
|
|
224
|
+
max_retries: 3 # Retries for failed generations
|
|
225
|
+
sample_retries: 2 # Retries for validation failures
|
|
226
|
+
max_tokens: 2000 # Max tokens per generation
|
|
177
227
|
|
|
178
228
|
# Optional: Override shared LLM settings
|
|
179
229
|
llm:
|
|
@@ -193,13 +243,13 @@ output:
|
|
|
193
243
|
batch_size: 3 # Parallel generation batch size
|
|
194
244
|
save_as: "api-dataset.jsonl"
|
|
195
245
|
|
|
196
|
-
|
|
197
|
-
huggingface:
|
|
198
|
-
|
|
199
|
-
|
|
246
|
+
Optional: Upload to Hugging Face
|
|
247
|
+
huggingface:
|
|
248
|
+
repository: "your-username/api-dataset-training-name"
|
|
249
|
+
tags: ["python", "programming"]
|
|
200
250
|
```
|
|
201
251
|
|
|
202
|
-
Run
|
|
252
|
+
Run generation by sourcing the `config.yaml`:
|
|
203
253
|
|
|
204
254
|
```bash
|
|
205
255
|
deepfabric generate config.yaml
|
|
@@ -209,6 +259,14 @@ deepfabric generate config.yaml
|
|
|
209
259
|
|
|
210
260
|
DeepFabric returns standard HuggingFace datasets, making it easy to integrate with any training framework.
|
|
211
261
|
|
|
262
|
+
### Colab Notebooks:
|
|
263
|
+
|
|
264
|
+
A quick way of seeing DeepFabric in action is via our notebooks in the [notebooks/](./notebooks/) folder or on Google Colab:
|
|
265
|
+
|
|
266
|
+
**Qwen4b Blender MCP**:
|
|
267
|
+
|
|
268
|
+
[](https://colab.research.google.com/drive/1EG1V40v5xkJKLf6Ra6W4378vYqlZNVWqb)
|
|
269
|
+
|
|
212
270
|
### 1. Generate Dataset
|
|
213
271
|
|
|
214
272
|
```bash
|
|
@@ -327,7 +385,6 @@ config = EvaluatorConfig(
|
|
|
327
385
|
model_path="Qwen/Qwen2.5-7B-Instruct", # Base model
|
|
328
386
|
adapter_path="./output/lora-adapter", # LoRA adapter path
|
|
329
387
|
backend="transformers",
|
|
330
|
-
use_unsloth=True, # Use Unsloth for adapters trained with Unsloth
|
|
331
388
|
load_in_4bit=True, # 4-bit quantization
|
|
332
389
|
max_seq_length=2048,
|
|
333
390
|
),
|
|
@@ -418,159 +475,6 @@ evaluator = Evaluator(config)
|
|
|
418
475
|
results = evaluator.evaluate(dataset=eval_dataset)
|
|
419
476
|
```
|
|
420
477
|
|
|
421
|
-
## Training Metrics
|
|
422
|
-
|
|
423
|
-
DeepFabric provides a training callback that automatically logs metrics to the DeepFabric cloud during model training. This enables real-time monitoring and tracking of training runs.
|
|
424
|
-
|
|
425
|
-
### Basic Usage with HuggingFace Trainer
|
|
426
|
-
|
|
427
|
-
```python
|
|
428
|
-
from transformers import Trainer, TrainingArguments
|
|
429
|
-
from deepfabric import DeepFabricCallback
|
|
430
|
-
|
|
431
|
-
# Set up training arguments
|
|
432
|
-
training_args = TrainingArguments(
|
|
433
|
-
output_dir="./output",
|
|
434
|
-
num_train_epochs=3,
|
|
435
|
-
per_device_train_batch_size=4,
|
|
436
|
-
logging_steps=10,
|
|
437
|
-
)
|
|
438
|
-
|
|
439
|
-
# Create trainer
|
|
440
|
-
trainer = Trainer(
|
|
441
|
-
model=model,
|
|
442
|
-
args=training_args,
|
|
443
|
-
train_dataset=train_dataset,
|
|
444
|
-
eval_dataset=eval_dataset,
|
|
445
|
-
)
|
|
446
|
-
|
|
447
|
-
# Add DeepFabric callback for metrics logging
|
|
448
|
-
trainer.add_callback(DeepFabricCallback(trainer))
|
|
449
|
-
|
|
450
|
-
# Train - metrics are automatically logged
|
|
451
|
-
trainer.train()
|
|
452
|
-
```
|
|
453
|
-
|
|
454
|
-
### Usage with TRL SFTTrainer
|
|
455
|
-
|
|
456
|
-
```python
|
|
457
|
-
from trl import SFTTrainer, SFTConfig
|
|
458
|
-
from deepfabric import DeepFabricCallback
|
|
459
|
-
|
|
460
|
-
trainer = SFTTrainer(
|
|
461
|
-
model=model,
|
|
462
|
-
tokenizer=tokenizer,
|
|
463
|
-
train_dataset=train_dataset,
|
|
464
|
-
args=SFTConfig(
|
|
465
|
-
output_dir="./output",
|
|
466
|
-
num_train_epochs=3,
|
|
467
|
-
logging_steps=10,
|
|
468
|
-
),
|
|
469
|
-
)
|
|
470
|
-
|
|
471
|
-
# Add callback - works with any Trainer-compatible class
|
|
472
|
-
trainer.add_callback(DeepFabricCallback(trainer))
|
|
473
|
-
trainer.train()
|
|
474
|
-
```
|
|
475
|
-
|
|
476
|
-
### Configuration Options
|
|
477
|
-
|
|
478
|
-
```python
|
|
479
|
-
from deepfabric import DeepFabricCallback
|
|
480
|
-
|
|
481
|
-
callback = DeepFabricCallback(
|
|
482
|
-
trainer=trainer, # Optional: Trainer instance
|
|
483
|
-
api_key="your-api-key", # Or set DEEPFABRIC_API_KEY env var
|
|
484
|
-
endpoint="https://api.deepfabric.ai", # Custom endpoint (optional)
|
|
485
|
-
enabled=True, # Disable to skip logging
|
|
486
|
-
)
|
|
487
|
-
```
|
|
488
|
-
|
|
489
|
-
### Environment Variables
|
|
490
|
-
|
|
491
|
-
```bash
|
|
492
|
-
# API key for authentication
|
|
493
|
-
export DEEPFABRIC_API_KEY="your-api-key"
|
|
494
|
-
|
|
495
|
-
# Custom API endpoint (optional)
|
|
496
|
-
export DEEPFABRIC_API_URL="https://api.deepfabric.ai"
|
|
497
|
-
```
|
|
498
|
-
|
|
499
|
-
### Logged Metrics
|
|
500
|
-
|
|
501
|
-
The callback automatically captures and logs:
|
|
502
|
-
|
|
503
|
-
| Metric Type | Examples |
|
|
504
|
-
|-------------|----------|
|
|
505
|
-
| Training | `loss`, `learning_rate`, `epoch`, `global_step` |
|
|
506
|
-
| Throughput | `train_runtime`, `train_samples_per_second` |
|
|
507
|
-
| Evaluation | `eval_loss`, `eval_accuracy` (when evaluation is run) |
|
|
508
|
-
| TRL-specific | `rewards/chosen`, `rewards/rejected`, `kl_divergence` |
|
|
509
|
-
| Checkpoints | Checkpoint save events with step numbers |
|
|
510
|
-
|
|
511
|
-
### Callback Events
|
|
512
|
-
|
|
513
|
-
```python
|
|
514
|
-
# The callback hooks into these Trainer events:
|
|
515
|
-
# - on_train_begin: Logs run start with training configuration
|
|
516
|
-
# - on_log: Logs training metrics (loss, lr, etc.)
|
|
517
|
-
# - on_evaluate: Logs evaluation metrics
|
|
518
|
-
# - on_save: Logs checkpoint events
|
|
519
|
-
# - on_train_end: Logs run completion and flushes pending metrics
|
|
520
|
-
```
|
|
521
|
-
|
|
522
|
-
### Non-Blocking Design
|
|
523
|
-
|
|
524
|
-
The callback uses a background thread to send metrics asynchronously, ensuring training is never blocked by network operations:
|
|
525
|
-
|
|
526
|
-
```python
|
|
527
|
-
from deepfabric.training import MetricsSender
|
|
528
|
-
|
|
529
|
-
# Direct access to sender for advanced use cases
|
|
530
|
-
sender = MetricsSender(
|
|
531
|
-
endpoint="https://api.deepfabric.ai",
|
|
532
|
-
api_key="your-key",
|
|
533
|
-
batch_size=10, # Batch metrics before sending
|
|
534
|
-
flush_interval=5.0, # Auto-flush every 5 seconds
|
|
535
|
-
max_queue_size=1000, # Queue capacity
|
|
536
|
-
)
|
|
537
|
-
|
|
538
|
-
# Manually send metrics
|
|
539
|
-
sender.send_metrics({"custom_metric": 0.95, "step": 100})
|
|
540
|
-
|
|
541
|
-
# Flush pending metrics (blocking)
|
|
542
|
-
sender.flush(timeout=30.0)
|
|
543
|
-
|
|
544
|
-
# Check sender statistics
|
|
545
|
-
print(sender.stats)
|
|
546
|
-
# {'metrics_sent': 150, 'metrics_dropped': 0, 'send_errors': 0, 'queue_size': 0}
|
|
547
|
-
```
|
|
548
|
-
|
|
549
|
-
### Interactive API Key Prompt
|
|
550
|
-
|
|
551
|
-
When running in an interactive environment (Jupyter notebook, terminal) without an API key configured, the callback will prompt for authentication:
|
|
552
|
-
|
|
553
|
-
```python
|
|
554
|
-
from deepfabric import DeepFabricCallback
|
|
555
|
-
|
|
556
|
-
# If DEEPFABRIC_API_KEY is not set, prompts for login
|
|
557
|
-
callback = DeepFabricCallback(trainer)
|
|
558
|
-
# > DeepFabric API key not found. Log in to enable cloud metrics.
|
|
559
|
-
# > Visit: https://app.deepfabric.ai/signup
|
|
560
|
-
```
|
|
561
|
-
|
|
562
|
-
### Disabling Metrics Logging
|
|
563
|
-
|
|
564
|
-
```python
|
|
565
|
-
# Disable via constructor
|
|
566
|
-
callback = DeepFabricCallback(trainer, enabled=False)
|
|
567
|
-
|
|
568
|
-
# Or set API key to None
|
|
569
|
-
callback = DeepFabricCallback(trainer, api_key=None)
|
|
570
|
-
|
|
571
|
-
# Or don't set DEEPFABRIC_API_KEY environment variable
|
|
572
|
-
```
|
|
573
|
-
|
|
574
478
|
## Providers
|
|
575
479
|
|
|
576
480
|
| Provider | Local/Cloud | Best For |
|
|
@@ -628,7 +532,7 @@ Enable tool tracing in your YAML config:
|
|
|
628
532
|
```yaml
|
|
629
533
|
generation:
|
|
630
534
|
conversation:
|
|
631
|
-
type:
|
|
535
|
+
type: cot
|
|
632
536
|
reasoning_style: agent
|
|
633
537
|
agent_mode: single_turn
|
|
634
538
|
|