witdem-analytics 0.2.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.
- witdem_analytics-0.2.0/.dockerignore +16 -0
- witdem_analytics-0.2.0/.env.example +18 -0
- witdem_analytics-0.2.0/.gitattributes +1 -0
- witdem_analytics-0.2.0/.github/workflows/pricing-catalog.yml +46 -0
- witdem_analytics-0.2.0/.github/workflows/release-analytics.yml +32 -0
- witdem_analytics-0.2.0/.github/workflows/release-container.yml +86 -0
- witdem_analytics-0.2.0/.github/workflows/release-sdk.yml +41 -0
- witdem_analytics-0.2.0/.github/workflows/test.yml +105 -0
- witdem_analytics-0.2.0/.gitignore +27 -0
- witdem_analytics-0.2.0/Dockerfile.witdem +27 -0
- witdem_analytics-0.2.0/PKG-INFO +218 -0
- witdem_analytics-0.2.0/README.md +198 -0
- witdem_analytics-0.2.0/compatibility.json +47 -0
- witdem_analytics-0.2.0/deploy/Caddyfile +14 -0
- witdem_analytics-0.2.0/deploy/empty-pricing.yaml +4 -0
- witdem_analytics-0.2.0/deploy/remote-entrypoint.sh +26 -0
- witdem_analytics-0.2.0/docker-compose.dev.yml +27 -0
- witdem_analytics-0.2.0/docker-compose.yml +118 -0
- witdem_analytics-0.2.0/docs/architecture.md +44 -0
- witdem_analytics-0.2.0/docs/assets/duckdb.svg +1 -0
- witdem_analytics-0.2.0/docs/assets/duckle.png +0 -0
- witdem_analytics-0.2.0/docs/assets/tanstack.svg +23 -0
- witdem_analytics-0.2.0/docs/changelog.md +15 -0
- witdem_analytics-0.2.0/docs/concepts.md +62 -0
- witdem_analytics-0.2.0/docs/configuration.md +333 -0
- witdem_analytics-0.2.0/docs/contract-tutorial.md +405 -0
- witdem_analytics-0.2.0/docs/contracts/01-boolean-goal.yaml +35 -0
- witdem_analytics-0.2.0/docs/contracts/02-classification.yaml +45 -0
- witdem_analytics-0.2.0/docs/contracts/03-quality-threshold.yaml +41 -0
- witdem_analytics-0.2.0/docs/contracts/04-multiple-assurance-checks.yaml +52 -0
- witdem_analytics-0.2.0/docs/contracts/05-routing-and-escalation.yaml +41 -0
- witdem_analytics-0.2.0/docs/contracts/06-research-approval-loop.yaml +44 -0
- witdem_analytics-0.2.0/docs/contracts/07-rag-grounding.yaml +55 -0
- witdem_analytics-0.2.0/docs/contracts/08-diagnostic-metrics.yaml +38 -0
- witdem_analytics-0.2.0/docs/contracts/09-chat-hard-and-loose.yaml +61 -0
- witdem_analytics-0.2.0/docs/dashboard.md +59 -0
- witdem_analytics-0.2.0/docs/development.md +22 -0
- witdem_analytics-0.2.0/docs/examples.md +85 -0
- witdem_analytics-0.2.0/docs/getting-started.md +141 -0
- witdem_analytics-0.2.0/docs/integrations/anthropic.md +62 -0
- witdem_analytics-0.2.0/docs/integrations/haystack.md +152 -0
- witdem_analytics-0.2.0/docs/integrations/langchain.md +82 -0
- witdem_analytics-0.2.0/docs/integrations/langgraph.md +107 -0
- witdem_analytics-0.2.0/docs/integrations/litellm.md +67 -0
- witdem_analytics-0.2.0/docs/integrations/native-python.md +103 -0
- witdem_analytics-0.2.0/docs/integrations/openai-agents.md +46 -0
- witdem_analytics-0.2.0/docs/integrations/smolagents.md +42 -0
- witdem_analytics-0.2.0/docs/npm-launcher.md +73 -0
- witdem_analytics-0.2.0/docs/operations.md +61 -0
- witdem_analytics-0.2.0/docs/pricing.md +93 -0
- witdem_analytics-0.2.0/docs/providers/anthropic.md +38 -0
- witdem_analytics-0.2.0/docs/providers/azure-openai.md +32 -0
- witdem_analytics-0.2.0/docs/providers/bedrock.md +30 -0
- witdem_analytics-0.2.0/docs/providers/cohere.md +24 -0
- witdem_analytics-0.2.0/docs/providers/deepseek.md +31 -0
- witdem_analytics-0.2.0/docs/providers/mistral.md +29 -0
- witdem_analytics-0.2.0/docs/providers/ollama.md +26 -0
- witdem_analytics-0.2.0/docs/providers/openai.md +39 -0
- witdem_analytics-0.2.0/docs/providers/openrouter.md +54 -0
- witdem_analytics-0.2.0/docs/providers/vertex-ai.md +29 -0
- witdem_analytics-0.2.0/docs/providers.md +73 -0
- witdem_analytics-0.2.0/docs/sdk.md +176 -0
- witdem_analytics-0.2.0/docs/troubleshooting.md +125 -0
- witdem_analytics-0.2.0/examples/.env.example +12 -0
- witdem_analytics-0.2.0/examples/anthropic/basic_agent/.env.example +3 -0
- witdem_analytics-0.2.0/examples/anthropic/basic_agent/.witdem/witdem.yaml +40 -0
- witdem_analytics-0.2.0/examples/anthropic/basic_agent/app.py +14 -0
- witdem_analytics-0.2.0/examples/anthropic/basic_agent/otel_only.py +31 -0
- witdem_analytics-0.2.0/examples/anthropic/basic_agent/pyproject.toml +23 -0
- witdem_analytics-0.2.0/examples/anthropic/basic_agent/run.py +90 -0
- witdem_analytics-0.2.0/examples/anthropic/basic_agent/sdk_enriched.py +15 -0
- witdem_analytics-0.2.0/examples/anthropic/basic_agent/tests/test_example.py +19 -0
- witdem_analytics-0.2.0/examples/anthropic/basic_agent/uv.lock +958 -0
- witdem_analytics-0.2.0/examples/anthropic/tool_loop/.env.example +3 -0
- witdem_analytics-0.2.0/examples/anthropic/tool_loop/.witdem/witdem.yaml +40 -0
- witdem_analytics-0.2.0/examples/anthropic/tool_loop/app.py +33 -0
- witdem_analytics-0.2.0/examples/anthropic/tool_loop/otel_only.py +25 -0
- witdem_analytics-0.2.0/examples/anthropic/tool_loop/pyproject.toml +23 -0
- witdem_analytics-0.2.0/examples/anthropic/tool_loop/run.py +144 -0
- witdem_analytics-0.2.0/examples/anthropic/tool_loop/sdk_enriched.py +15 -0
- witdem_analytics-0.2.0/examples/anthropic/tool_loop/tests/test_example.py +32 -0
- witdem_analytics-0.2.0/examples/anthropic/tool_loop/uv.lock +958 -0
- witdem_analytics-0.2.0/examples/cloud/azure/.env.example +8 -0
- witdem_analytics-0.2.0/examples/cloud/azure/.witdem/witdem.yaml +40 -0
- witdem_analytics-0.2.0/examples/cloud/azure/app.py +37 -0
- witdem_analytics-0.2.0/examples/cloud/azure/otel_only.py +30 -0
- witdem_analytics-0.2.0/examples/cloud/azure/pyproject.toml +23 -0
- witdem_analytics-0.2.0/examples/cloud/azure/sdk_enriched.py +19 -0
- witdem_analytics-0.2.0/examples/cloud/azure/tests/test_example.py +19 -0
- witdem_analytics-0.2.0/examples/cloud/azure/uv.lock +956 -0
- witdem_analytics-0.2.0/examples/cloud/bedrock/.env.example +8 -0
- witdem_analytics-0.2.0/examples/cloud/bedrock/.witdem/witdem.yaml +40 -0
- witdem_analytics-0.2.0/examples/cloud/bedrock/app.py +33 -0
- witdem_analytics-0.2.0/examples/cloud/bedrock/otel_only.py +30 -0
- witdem_analytics-0.2.0/examples/cloud/bedrock/pyproject.toml +23 -0
- witdem_analytics-0.2.0/examples/cloud/bedrock/sdk_enriched.py +19 -0
- witdem_analytics-0.2.0/examples/cloud/bedrock/tests/test_example.py +19 -0
- witdem_analytics-0.2.0/examples/cloud/bedrock/uv.lock +878 -0
- witdem_analytics-0.2.0/examples/cloud/vertex/.env.example +7 -0
- witdem_analytics-0.2.0/examples/cloud/vertex/.witdem/witdem.yaml +40 -0
- witdem_analytics-0.2.0/examples/cloud/vertex/app.py +33 -0
- witdem_analytics-0.2.0/examples/cloud/vertex/otel_only.py +30 -0
- witdem_analytics-0.2.0/examples/cloud/vertex/pyproject.toml +23 -0
- witdem_analytics-0.2.0/examples/cloud/vertex/sdk_enriched.py +19 -0
- witdem_analytics-0.2.0/examples/cloud/vertex/tests/test_example.py +19 -0
- witdem_analytics-0.2.0/examples/cloud/vertex/uv.lock +1191 -0
- witdem_analytics-0.2.0/examples/haystack/compatibility/runner.py +686 -0
- witdem_analytics-0.2.0/examples/haystack/demo/.env.example +3 -0
- witdem_analytics-0.2.0/examples/haystack/demo/Dockerfile +38 -0
- witdem_analytics-0.2.0/examples/haystack/demo/pyproject.toml +92 -0
- witdem_analytics-0.2.0/examples/haystack/demo/src/agent_demo/__init__.py +13 -0
- witdem_analytics-0.2.0/examples/haystack/demo/src/agent_demo/api.py +140 -0
- witdem_analytics-0.2.0/examples/haystack/demo/src/agent_demo/enrichment.py +82 -0
- witdem_analytics-0.2.0/examples/haystack/demo/src/agent_demo/fake_provider.py +91 -0
- witdem_analytics-0.2.0/examples/haystack/demo/src/agent_demo/otel_setup.py +206 -0
- witdem_analytics-0.2.0/examples/haystack/demo/src/agent_demo/scenarios/__init__.py +33 -0
- witdem_analytics-0.2.0/examples/haystack/demo/src/agent_demo/scenarios/correction_loop.py +35 -0
- witdem_analytics-0.2.0/examples/haystack/demo/src/agent_demo/scenarios/failure_recovery.py +36 -0
- witdem_analytics-0.2.0/examples/haystack/demo/src/agent_demo/scenarios/nested.py +31 -0
- witdem_analytics-0.2.0/examples/haystack/demo/src/agent_demo/scenarios/simple_success.py +24 -0
- witdem_analytics-0.2.0/examples/haystack/demo/src/agent_demo/scenarios/terminal_failure.py +34 -0
- witdem_analytics-0.2.0/examples/haystack/demo/src/agent_demo/scenarios/tool_calling.py +26 -0
- witdem_analytics-0.2.0/examples/haystack/demo/src/agent_demo/workflow.py +472 -0
- witdem_analytics-0.2.0/examples/haystack/demo/tests/conftest.py +32 -0
- witdem_analytics-0.2.0/examples/haystack/demo/tests/test_health.py +13 -0
- witdem_analytics-0.2.0/examples/haystack/demo/tests/test_mode_equivalence.py +72 -0
- witdem_analytics-0.2.0/examples/haystack/demo/tests/test_no_witdem_sdk_import.py +85 -0
- witdem_analytics-0.2.0/examples/haystack/demo/tests/test_scenario_shapes_distinct.py +52 -0
- witdem_analytics-0.2.0/examples/haystack/demo/tests/test_scenarios_telemetry_only.py +185 -0
- witdem_analytics-0.2.0/examples/haystack/demo/tests/test_sdk_enriched.py +59 -0
- witdem_analytics-0.2.0/examples/haystack/demo/tests/test_two_mode_topology_equivalence.py +310 -0
- witdem_analytics-0.2.0/examples/haystack/demo/uv.lock +1326 -0
- witdem_analytics-0.2.0/examples/haystack/pipeline/.env.example +3 -0
- witdem_analytics-0.2.0/examples/haystack/pipeline/.witdem/witdem.yaml +40 -0
- witdem_analytics-0.2.0/examples/haystack/pipeline/README.md +31 -0
- witdem_analytics-0.2.0/examples/haystack/pipeline/app.py +74 -0
- witdem_analytics-0.2.0/examples/haystack/pipeline/otel_only.py +29 -0
- witdem_analytics-0.2.0/examples/haystack/pipeline/pyproject.toml +25 -0
- witdem_analytics-0.2.0/examples/haystack/pipeline/run.py +83 -0
- witdem_analytics-0.2.0/examples/haystack/pipeline/sdk_enriched.py +28 -0
- witdem_analytics-0.2.0/examples/haystack/pipeline/tests/test_example.py +19 -0
- witdem_analytics-0.2.0/examples/haystack/pipeline/tests/test_parallel_pipeline.py +34 -0
- witdem_analytics-0.2.0/examples/haystack/pipeline/uv.lock +1799 -0
- witdem_analytics-0.2.0/examples/integrations/fixture_demo.py +38 -0
- witdem_analytics-0.2.0/examples/integrations/live_runtime_runs.py +38 -0
- witdem_analytics-0.2.0/examples/langchain/runnable_pipeline/.env.example +3 -0
- witdem_analytics-0.2.0/examples/langchain/runnable_pipeline/.witdem/witdem.yaml +40 -0
- witdem_analytics-0.2.0/examples/langchain/runnable_pipeline/app.py +18 -0
- witdem_analytics-0.2.0/examples/langchain/runnable_pipeline/otel_only.py +22 -0
- witdem_analytics-0.2.0/examples/langchain/runnable_pipeline/pyproject.toml +24 -0
- witdem_analytics-0.2.0/examples/langchain/runnable_pipeline/run.py +73 -0
- witdem_analytics-0.2.0/examples/langchain/runnable_pipeline/sdk_enriched.py +12 -0
- witdem_analytics-0.2.0/examples/langchain/runnable_pipeline/tests/test_example.py +19 -0
- witdem_analytics-0.2.0/examples/langchain/runnable_pipeline/uv.lock +1968 -0
- witdem_analytics-0.2.0/examples/langgraph/state_graph/.env.example +1 -0
- witdem_analytics-0.2.0/examples/langgraph/state_graph/.witdem/witdem.yaml +40 -0
- witdem_analytics-0.2.0/examples/langgraph/state_graph/app.py +31 -0
- witdem_analytics-0.2.0/examples/langgraph/state_graph/otel_only.py +22 -0
- witdem_analytics-0.2.0/examples/langgraph/state_graph/pyproject.toml +23 -0
- witdem_analytics-0.2.0/examples/langgraph/state_graph/run.py +92 -0
- witdem_analytics-0.2.0/examples/langgraph/state_graph/sdk_enriched.py +13 -0
- witdem_analytics-0.2.0/examples/langgraph/state_graph/tests/test_example.py +19 -0
- witdem_analytics-0.2.0/examples/langgraph/state_graph/uv.lock +1625 -0
- witdem_analytics-0.2.0/examples/ollama/basic/.env.example +5 -0
- witdem_analytics-0.2.0/examples/ollama/basic/.witdem/witdem.yaml +40 -0
- witdem_analytics-0.2.0/examples/ollama/basic/app.py +30 -0
- witdem_analytics-0.2.0/examples/ollama/basic/otel_only.py +30 -0
- witdem_analytics-0.2.0/examples/ollama/basic/pyproject.toml +23 -0
- witdem_analytics-0.2.0/examples/ollama/basic/sdk_enriched.py +19 -0
- witdem_analytics-0.2.0/examples/ollama/basic/tests/test_example.py +19 -0
- witdem_analytics-0.2.0/examples/ollama/basic/uv.lock +821 -0
- witdem_analytics-0.2.0/examples/openai/basic_agent/.env.example +3 -0
- witdem_analytics-0.2.0/examples/openai/basic_agent/.witdem/witdem.yaml +40 -0
- witdem_analytics-0.2.0/examples/openai/basic_agent/app.py +22 -0
- witdem_analytics-0.2.0/examples/openai/basic_agent/otel_only.py +26 -0
- witdem_analytics-0.2.0/examples/openai/basic_agent/pyproject.toml +23 -0
- witdem_analytics-0.2.0/examples/openai/basic_agent/run.py +79 -0
- witdem_analytics-0.2.0/examples/openai/basic_agent/sdk_enriched.py +14 -0
- witdem_analytics-0.2.0/examples/openai/basic_agent/tests/test_example.py +19 -0
- witdem_analytics-0.2.0/examples/openai/basic_agent/uv.lock +1757 -0
- witdem_analytics-0.2.0/examples/openai/multi_agent/.env.example +3 -0
- witdem_analytics-0.2.0/examples/openai/multi_agent/.witdem/witdem.yaml +40 -0
- witdem_analytics-0.2.0/examples/openai/multi_agent/app.py +21 -0
- witdem_analytics-0.2.0/examples/openai/multi_agent/otel_only.py +22 -0
- witdem_analytics-0.2.0/examples/openai/multi_agent/pyproject.toml +23 -0
- witdem_analytics-0.2.0/examples/openai/multi_agent/run.py +75 -0
- witdem_analytics-0.2.0/examples/openai/multi_agent/sdk_enriched.py +12 -0
- witdem_analytics-0.2.0/examples/openai/multi_agent/tests/test_example.py +19 -0
- witdem_analytics-0.2.0/examples/openai/multi_agent/uv.lock +1757 -0
- witdem_analytics-0.2.0/examples/product-factory/.env.example +32 -0
- witdem_analytics-0.2.0/examples/product-factory/.witdem/witdem.yaml +52 -0
- witdem_analytics-0.2.0/examples/product-factory/cases/borderline-escalation.yaml +20 -0
- witdem_analytics-0.2.0/examples/product-factory/cases/clear-non-qualification.yaml +20 -0
- witdem_analytics-0.2.0/examples/product-factory/cases/clear-qualification.yaml +20 -0
- witdem_analytics-0.2.0/examples/product-factory/cases/recoverable-evidence-gap.yaml +23 -0
- witdem_analytics-0.2.0/examples/product-factory/config/domains/product_factory.yaml +95 -0
- witdem_analytics-0.2.0/examples/product-factory/pyproject.toml +69 -0
- witdem_analytics-0.2.0/examples/product-factory/run.py +10 -0
- witdem_analytics-0.2.0/examples/product-factory/scripts/validate_fresh.py +341 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/__init__.py +3 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/analytics/__init__.py +5 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/analytics/semantic.py +214 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/analytics/witdem_sdk_semantics.py +41 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/cli.py +121 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/config.py +129 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/domain/__init__.py +1 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/domain/config.py +217 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/domain/evaluation.py +67 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/domain/models.py +341 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/experiments/__init__.py +1 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/experiments/cost.py +5 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/experiments/harness.py +463 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/experiments/haystack_compatibility.py +686 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/experiments/inspection.py +157 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/experiments/live_heterogeneous.py +960 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/experiments/real_company_corpus.py +549 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/experiments/report.py +71 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/experiments/synthetic_corpus.py +1799 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/persistence/__init__.py +1 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/persistence/store.py +57 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/providers/__init__.py +1 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/providers/factory.py +189 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/reference/__init__.py +6 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/reference/cases.py +52 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/reference/contracts.py +220 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/reference/gateways.py +532 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/reference/matrix.py +246 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/reference/policy.py +108 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/reference/profiles.py +30 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/reference/prompts.py +16 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/reference/runner.py +234 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/reference/runtimes/__init__.py +18 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/reference/runtimes/anthropic_messages.py +35 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/reference/runtimes/base.py +275 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/reference/runtimes/haystack.py +124 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/reference/runtimes/langchain.py +76 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/reference/runtimes/langgraph.py +120 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/reference/runtimes/openai_agents.py +41 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/research/__init__.py +1 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/research/sources.py +595 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/service.py +394 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/telemetry.py +102 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/workflow/__init__.py +1 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/workflow/components.py +1422 -0
- witdem_analytics-0.2.0/examples/product-factory/src/product_factory_app/workflow/pipeline.py +134 -0
- witdem_analytics-0.2.0/examples/product-factory/tests/conftest.py +27 -0
- witdem_analytics-0.2.0/examples/product-factory/tests/e2e/test_research.py +200 -0
- witdem_analytics-0.2.0/examples/product-factory/tests/integration/test_inspection.py +70 -0
- witdem_analytics-0.2.0/examples/product-factory/tests/integration/test_pipeline.py +22 -0
- witdem_analytics-0.2.0/examples/product-factory/tests/integration/test_telemetry.py +58 -0
- witdem_analytics-0.2.0/examples/product-factory/tests/reference/test_contract.py +235 -0
- witdem_analytics-0.2.0/examples/product-factory/tests/reference/test_policy.py +92 -0
- witdem_analytics-0.2.0/examples/product-factory/tests/unit/test_components.py +264 -0
- witdem_analytics-0.2.0/examples/product-factory/tests/unit/test_config.py +24 -0
- witdem_analytics-0.2.0/examples/product-factory/tests/unit/test_cost.py +39 -0
- witdem_analytics-0.2.0/examples/product-factory/tests/unit/test_experiment_selection.py +29 -0
- witdem_analytics-0.2.0/examples/product-factory/tests/unit/test_experiments.py +33 -0
- witdem_analytics-0.2.0/examples/product-factory/tests/unit/test_live_heterogeneous.py +151 -0
- witdem_analytics-0.2.0/examples/product-factory/tests/unit/test_models.py +24 -0
- witdem_analytics-0.2.0/examples/product-factory/tests/unit/test_sources.py +41 -0
- witdem_analytics-0.2.0/examples/product-factory/uv.lock +1886 -0
- witdem_analytics-0.2.0/examples/run_live.py +256 -0
- witdem_analytics-0.2.0/npm/README.md +19 -0
- witdem_analytics-0.2.0/npm/bin/witdem.mjs +8 -0
- witdem_analytics-0.2.0/npm/compose.yaml +58 -0
- witdem_analytics-0.2.0/npm/package-lock.json +18 -0
- witdem_analytics-0.2.0/npm/package.json +36 -0
- witdem_analytics-0.2.0/npm/src/cli.mjs +219 -0
- witdem_analytics-0.2.0/npm/test/cli.test.mjs +66 -0
- witdem_analytics-0.2.0/pyproject.toml +71 -0
- witdem_analytics-0.2.0/src/witdem/__init__.py +3 -0
- witdem_analytics-0.2.0/src/witdem/adapters/__init__.py +13 -0
- witdem_analytics-0.2.0/src/witdem/adapters/base.py +31 -0
- witdem_analytics-0.2.0/src/witdem/adapters/haystack_adapter.py +59 -0
- witdem_analytics-0.2.0/src/witdem/adapters/providers.py +110 -0
- witdem_analytics-0.2.0/src/witdem/adapters/registry.py +51 -0
- witdem_analytics-0.2.0/src/witdem/analytics/__init__.py +74 -0
- witdem_analytics-0.2.0/src/witdem/analytics/contracts/__init__.py +29 -0
- witdem_analytics-0.2.0/src/witdem/analytics/contracts/read_models.py +199 -0
- witdem_analytics-0.2.0/src/witdem/analytics/core.py +108 -0
- witdem_analytics-0.2.0/src/witdem/analytics/cost.py +531 -0
- witdem_analytics-0.2.0/src/witdem/analytics/derived.py +104 -0
- witdem_analytics-0.2.0/src/witdem/analytics/identity.py +319 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/entities/models.sql +10 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/entities/provider_values.sql +4 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/entities/providers.sql +9 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/execution/business_outcome.sql +5 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/execution/evaluations_for_execution.sql +4 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/execution/events_for_execution.sql +4 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/execution/execution_detail.sql +3 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/execution/execution_population.sql +4 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/execution/execution_timeline.sql +4 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/execution/links_for_execution.sql +3 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/execution/outcomes_for_execution.sql +4 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/execution/product_goal.sql +5 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/execution/runtime_outcome.sql +8 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/failures/failure_patterns.sql +11 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/overview/cost_summary.sql +8 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/overview/execution_health.sql +31 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/overview/performance.sql +9 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/overview/product_goals.sql +4 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/overview/success_metrics.sql +11 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/paths/loops.sql +4 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/paths/path_frequency.sql +3 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/shared/capabilities.sql +12 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/shared/evaluations_count.sql +2 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/shared/events_capabilities.sql +4 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/shared/filter_completed.sql +7 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/shared/filter_end_date.sql +1 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/shared/filter_failed.sql +7 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/shared/filter_has_failure.sql +6 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/shared/filter_provider.sql +6 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/shared/filter_running.sql +1 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/shared/filter_start_date.sql +1 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/shared/metadata.sql +1 -0
- witdem_analytics-0.2.0/src/witdem/analytics/queries/shared/outcomes_count.sql +2 -0
- witdem_analytics-0.2.0/src/witdem/analytics/read_model.py +337 -0
- witdem_analytics-0.2.0/src/witdem/analytics/repository/__init__.py +6 -0
- witdem_analytics-0.2.0/src/witdem/analytics/repository/analytics_repository.py +2335 -0
- witdem_analytics-0.2.0/src/witdem/analytics/repository/backend.py +51 -0
- witdem_analytics-0.2.0/src/witdem/analytics/repository/sql_loader.py +42 -0
- witdem_analytics-0.2.0/src/witdem/analytics/repository/state.py +55 -0
- witdem_analytics-0.2.0/src/witdem/analytics/runtime.py +1321 -0
- witdem_analytics-0.2.0/src/witdem/analytics/schema/analytics_tables.sql +73 -0
- witdem_analytics-0.2.0/src/witdem/analytics/schema.py +108 -0
- witdem_analytics-0.2.0/src/witdem/analytics/serving.py +465 -0
- witdem_analytics-0.2.0/src/witdem/api.py +144 -0
- witdem_analytics-0.2.0/src/witdem/auth.py +64 -0
- witdem_analytics-0.2.0/src/witdem/cli.py +520 -0
- witdem_analytics-0.2.0/src/witdem/config.py +85 -0
- witdem_analytics-0.2.0/src/witdem/dashboard/__init__.py +5 -0
- witdem_analytics-0.2.0/src/witdem/dashboard/app.py +129 -0
- witdem_analytics-0.2.0/src/witdem/dashboard/service.py +178 -0
- witdem_analytics-0.2.0/src/witdem/dashboard/static/assets/advanced-workflow-graph-CAdAoHLC.js +7 -0
- witdem_analytics-0.2.0/src/witdem/dashboard/static/assets/index-BCd8FOuZ.js +73 -0
- witdem_analytics-0.2.0/src/witdem/dashboard/static/assets/index-CnSnjiif.css +1 -0
- witdem_analytics-0.2.0/src/witdem/dashboard/static/index.html +3 -0
- witdem_analytics-0.2.0/src/witdem/elt/__init__.py +7 -0
- witdem_analytics-0.2.0/src/witdem/elt/adapter_stage.py +115 -0
- witdem_analytics-0.2.0/src/witdem/elt/publisher.py +36 -0
- witdem_analytics-0.2.0/src/witdem/elt/worker.py +193 -0
- witdem_analytics-0.2.0/src/witdem/elt/workspace/pipelines/normalize.pipeline.json +59 -0
- witdem_analytics-0.2.0/src/witdem/ingest/__init__.py +1 -0
- witdem_analytics-0.2.0/src/witdem/ingest/corpus.py +222 -0
- witdem_analytics-0.2.0/src/witdem/ingest/correlate.py +374 -0
- witdem_analytics-0.2.0/src/witdem/ingest/live_db.py +633 -0
- witdem_analytics-0.2.0/src/witdem/ingest/otlp_http.py +241 -0
- witdem_analytics-0.2.0/src/witdem/ingest/raw_store.py +195 -0
- witdem_analytics-0.2.0/src/witdem/ingest/sdk_ingest.py +183 -0
- witdem_analytics-0.2.0/src/witdem/ingest/sdk_store.py +172 -0
- witdem_analytics-0.2.0/src/witdem/integrations/__init__.py +12 -0
- witdem_analytics-0.2.0/src/witdem/integrations/adapters/__init__.py +14 -0
- witdem_analytics-0.2.0/src/witdem/integrations/adapters/claude.py +158 -0
- witdem_analytics-0.2.0/src/witdem/integrations/adapters/langchain.py +173 -0
- witdem_analytics-0.2.0/src/witdem/integrations/adapters/langgraph.py +117 -0
- witdem_analytics-0.2.0/src/witdem/integrations/adapters/openai_agents.py +294 -0
- witdem_analytics-0.2.0/src/witdem/integrations/adapters/otel.py +34 -0
- witdem_analytics-0.2.0/src/witdem/integrations/mapping.py +266 -0
- witdem_analytics-0.2.0/src/witdem/integrations/models/__init__.py +4 -0
- witdem_analytics-0.2.0/src/witdem/integrations/models/normalized_operation.py +42 -0
- witdem_analytics-0.2.0/src/witdem/integrations/models/normalized_span.py +60 -0
- witdem_analytics-0.2.0/src/witdem/integrations/normalizers/__init__.py +5 -0
- witdem_analytics-0.2.0/src/witdem/integrations/normalizers/genai.py +141 -0
- witdem_analytics-0.2.0/src/witdem/integrations/normalizers/openinference.py +109 -0
- witdem_analytics-0.2.0/src/witdem/integrations/normalizers/otel.py +176 -0
- witdem_analytics-0.2.0/src/witdem/pricing/__init__.py +10 -0
- witdem_analytics-0.2.0/src/witdem/pricing/catalog.yaml +1004 -0
- witdem_analytics-0.2.0/src/witdem/pricing/sources.yaml +186 -0
- witdem_analytics-0.2.0/src/witdem/pricing/update.py +191 -0
- witdem_analytics-0.2.0/src/witdem/protocol.py +5 -0
- witdem_analytics-0.2.0/src/witdem/py.typed +1 -0
- witdem_analytics-0.2.0/src/witdem/retention.py +164 -0
- witdem_analytics-0.2.0/src/witdem/telemetry/__init__.py +5 -0
- witdem_analytics-0.2.0/src/witdem/telemetry/otel.py +193 -0
- witdem_analytics-0.2.0/tests/fixtures/sdk-wire-v1-oldest.json +17 -0
- witdem_analytics-0.2.0/tests/test_analytics_repository_architecture.py +118 -0
- witdem_analytics-0.2.0/tests/test_auth.py +72 -0
- witdem_analytics-0.2.0/tests/test_config_cli.py +48 -0
- witdem_analytics-0.2.0/tests/test_dashboard_api.py +211 -0
- witdem_analytics-0.2.0/tests/test_elt_adapter_stage.py +233 -0
- witdem_analytics-0.2.0/tests/test_elt_worker.py +233 -0
- witdem_analytics-0.2.0/tests/test_example_tutorial_contracts.py +87 -0
- witdem_analytics-0.2.0/tests/test_generic_execution_correlation.py +21 -0
- witdem_analytics-0.2.0/tests/test_import_boundaries.py +61 -0
- witdem_analytics-0.2.0/tests/test_ingest_corpus.py +73 -0
- witdem_analytics-0.2.0/tests/test_integrations.py +487 -0
- witdem_analytics-0.2.0/tests/test_live_store.py +53 -0
- witdem_analytics-0.2.0/tests/test_pricing_catalog.py +246 -0
- witdem_analytics-0.2.0/tests/test_pricing_update.py +107 -0
- witdem_analytics-0.2.0/tests/test_primary_tutorial_contract.py +70 -0
- witdem_analytics-0.2.0/tests/test_protocol_compatibility.py +30 -0
- witdem_analytics-0.2.0/tests/test_provider_adapters.py +73 -0
- witdem_analytics-0.2.0/tests/test_readiness.py +35 -0
- witdem_analytics-0.2.0/tests/test_remote_compose.py +43 -0
- witdem_analytics-0.2.0/tests/test_repeated_patterns.py +59 -0
- witdem_analytics-0.2.0/tests/test_retention.py +157 -0
- witdem_analytics-0.2.0/tests/test_runtime_semantic_stages.py +64 -0
- witdem_analytics-0.2.0/uv.lock +1592 -0
- witdem_analytics-0.2.0/web/index.html +1 -0
- witdem_analytics-0.2.0/web/package-lock.json +5313 -0
- witdem_analytics-0.2.0/web/package.json +38 -0
- witdem_analytics-0.2.0/web/postcss.config.js +1 -0
- witdem_analytics-0.2.0/web/src/advanced-workflow-graph.test.ts +173 -0
- witdem_analytics-0.2.0/web/src/advanced-workflow-graph.tsx +1065 -0
- witdem_analytics-0.2.0/web/src/api.ts +365 -0
- witdem_analytics-0.2.0/web/src/components.tsx +1102 -0
- witdem_analytics-0.2.0/web/src/main.tsx +15 -0
- witdem_analytics-0.2.0/web/src/outcome-colors.test.ts +57 -0
- witdem_analytics-0.2.0/web/src/outcome-colors.ts +49 -0
- witdem_analytics-0.2.0/web/src/pages.test.ts +27 -0
- witdem_analytics-0.2.0/web/src/pages.tsx +1354 -0
- witdem_analytics-0.2.0/web/src/styles.css +18 -0
- witdem_analytics-0.2.0/web/tailwind.config.ts +9 -0
- witdem_analytics-0.2.0/web/tsconfig.app.json +9 -0
- witdem_analytics-0.2.0/web/tsconfig.json +4 -0
- witdem_analytics-0.2.0/web/tsconfig.node.json +11 -0
- witdem_analytics-0.2.0/web/vite.config.ts +8 -0
- witdem_analytics-0.2.0/witdem-sdk/pyproject.toml +84 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/__init__.py +185 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/__main__.py +3 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/_config.py +38 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/_contract.py +1161 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/_correlation.py +64 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/_errors.py +15 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/_payload.py +80 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/_protocol.py +7 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/_telemetry.py +879 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/_transport.py +164 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/cli.py +101 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/integrations/__init__.py +3 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/integrations/_common.py +73 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/integrations/anthropic.py +163 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/integrations/claude_agent.py +135 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/integrations/generic.py +145 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/integrations/haystack.py +557 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/integrations/langchain.py +414 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/integrations/langgraph.py +221 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/integrations/litellm.py +396 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/integrations/openai_agents.py +281 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/integrations/openrouter.py +368 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/integrations/smolagents.py +145 -0
- witdem_analytics-0.2.0/witdem-sdk/src/witdem_sdk/py.typed +0 -0
- witdem_analytics-0.2.0/witdem-sdk/tests/conftest.py +69 -0
- witdem_analytics-0.2.0/witdem-sdk/tests/test_contract_tutorial.py +42 -0
- witdem_analytics-0.2.0/witdem-sdk/tests/test_contracts.py +696 -0
- witdem_analytics-0.2.0/witdem-sdk/tests/test_correlation.py +95 -0
- witdem_analytics-0.2.0/witdem-sdk/tests/test_gateway_integrations.py +241 -0
- witdem_analytics-0.2.0/witdem-sdk/tests/test_haystack_observation.py +194 -0
- witdem_analytics-0.2.0/witdem-sdk/tests/test_high_level_integrations.py +412 -0
- witdem_analytics-0.2.0/witdem-sdk/tests/test_langgraph_instrumentation.py +161 -0
- witdem_analytics-0.2.0/witdem-sdk/tests/test_optional_integrations.py +301 -0
- witdem_analytics-0.2.0/witdem-sdk/tests/test_public_api.py +253 -0
- witdem_analytics-0.2.0/witdem-sdk/tests/test_telemetry.py +282 -0
- witdem_analytics-0.2.0/witdem-sdk/tests/test_transport.py +181 -0
- witdem_analytics-0.2.0/witdem-sdk/uv.lock +4773 -0
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# Copy this file to .env for local development. Example folders may also
|
|
2
|
+
# contain their own .env files; keep real credentials out of version control.
|
|
3
|
+
OPENAI_API_KEY=
|
|
4
|
+
ANTHROPIC_API_KEY=
|
|
5
|
+
GOOGLE_API_KEY=
|
|
6
|
+
AWS_ACCESS_KEY_ID=
|
|
7
|
+
AWS_SECRET_ACCESS_KEY=
|
|
8
|
+
AZURE_API_KEY=
|
|
9
|
+
OLLAMA_HOST=http://localhost:11434
|
|
10
|
+
WITDEM_ENDPOINT=http://localhost:4318
|
|
11
|
+
|
|
12
|
+
# Optional authenticated remote profile. Leave unset for trusted localhost.
|
|
13
|
+
WITDEM_API_KEY=
|
|
14
|
+
WITDEM_INGEST_HOST=
|
|
15
|
+
WITDEM_DASHBOARD_HOSTNAME=
|
|
16
|
+
WITDEM_TLS_EMAIL=
|
|
17
|
+
WITDEM_DASHBOARD_USER=
|
|
18
|
+
WITDEM_DASHBOARD_PASSWORD_HASH=
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
*.duckdb filter=lfs diff=lfs merge=lfs -text
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
name: Refresh pricing catalog
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
schedule:
|
|
5
|
+
- cron: "17 6 * * 1"
|
|
6
|
+
workflow_dispatch:
|
|
7
|
+
|
|
8
|
+
permissions:
|
|
9
|
+
contents: write
|
|
10
|
+
pull-requests: write
|
|
11
|
+
|
|
12
|
+
concurrency:
|
|
13
|
+
group: pricing-catalog-refresh
|
|
14
|
+
cancel-in-progress: true
|
|
15
|
+
|
|
16
|
+
jobs:
|
|
17
|
+
refresh:
|
|
18
|
+
runs-on: ubuntu-latest
|
|
19
|
+
steps:
|
|
20
|
+
- uses: actions/checkout@v4
|
|
21
|
+
- uses: astral-sh/setup-uv@v6
|
|
22
|
+
with:
|
|
23
|
+
python-version: "3.12"
|
|
24
|
+
- run: uv sync --all-groups
|
|
25
|
+
- run: uv run python -m witdem.pricing.update
|
|
26
|
+
- run: uv run pytest -q tests/test_pricing_catalog.py tests/test_pricing_update.py
|
|
27
|
+
- name: Open or update the review pull request
|
|
28
|
+
env:
|
|
29
|
+
GH_TOKEN: ${{ github.token }}
|
|
30
|
+
BRANCH: automation/pricing-catalog
|
|
31
|
+
run: |
|
|
32
|
+
if git diff --quiet -- src/witdem/pricing/catalog.yaml; then
|
|
33
|
+
echo "Pricing catalog is already current."
|
|
34
|
+
exit 0
|
|
35
|
+
fi
|
|
36
|
+
git config user.name "github-actions[bot]"
|
|
37
|
+
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
|
|
38
|
+
git checkout -B "$BRANCH"
|
|
39
|
+
git add src/witdem/pricing/catalog.yaml
|
|
40
|
+
git commit -m "chore: refresh pricing catalog"
|
|
41
|
+
git push --force origin "$BRANCH"
|
|
42
|
+
test "$(gh pr list --head "$BRANCH" --state open --json number --jq length)" != "0" || gh pr create \
|
|
43
|
+
--base main \
|
|
44
|
+
--head "$BRANCH" \
|
|
45
|
+
--title "chore: refresh pricing catalog" \
|
|
46
|
+
--body "Automated weekly pricing snapshot refresh. Review every changed rate against the official source URL stored on the catalog entry before merging."
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
name: Release witdem-analytics
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
workflow_dispatch:
|
|
5
|
+
push:
|
|
6
|
+
tags: ["analytics-v*"]
|
|
7
|
+
|
|
8
|
+
permissions:
|
|
9
|
+
contents: read
|
|
10
|
+
id-token: write
|
|
11
|
+
|
|
12
|
+
jobs:
|
|
13
|
+
publish:
|
|
14
|
+
runs-on: ubuntu-latest
|
|
15
|
+
environment: pypi
|
|
16
|
+
steps:
|
|
17
|
+
- uses: actions/checkout@v4
|
|
18
|
+
- uses: actions/setup-python@v5
|
|
19
|
+
with:
|
|
20
|
+
python-version: "3.12"
|
|
21
|
+
- run: python -m pip install build twine
|
|
22
|
+
- run: python -m pip install -e . pytest
|
|
23
|
+
- run: python -m pytest -q tests/test_protocol_compatibility.py
|
|
24
|
+
- run: python -m build
|
|
25
|
+
- run: python -m twine check dist/*
|
|
26
|
+
- name: Smoke-test built wheel
|
|
27
|
+
run: |
|
|
28
|
+
python -m venv /tmp/witdem-wheel
|
|
29
|
+
/tmp/witdem-wheel/bin/pip install dist/*.whl
|
|
30
|
+
/tmp/witdem-wheel/bin/witdem version
|
|
31
|
+
/tmp/witdem-wheel/bin/witdem doctor --port 14318 --dashboard-port 18501
|
|
32
|
+
- uses: pypa/gh-action-pypi-publish@release/v1
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
name: Release container and npm launcher
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
workflow_dispatch:
|
|
5
|
+
inputs:
|
|
6
|
+
version:
|
|
7
|
+
description: Released witdem-analytics version
|
|
8
|
+
required: true
|
|
9
|
+
type: string
|
|
10
|
+
|
|
11
|
+
permissions:
|
|
12
|
+
contents: read
|
|
13
|
+
packages: write
|
|
14
|
+
id-token: write
|
|
15
|
+
|
|
16
|
+
jobs:
|
|
17
|
+
publish:
|
|
18
|
+
runs-on: ubuntu-latest
|
|
19
|
+
steps:
|
|
20
|
+
- uses: actions/checkout@v4
|
|
21
|
+
- name: Verify release versions agree
|
|
22
|
+
env:
|
|
23
|
+
RELEASE_VERSION: ${{ inputs.version }}
|
|
24
|
+
run: |
|
|
25
|
+
python - <<'PY'
|
|
26
|
+
import json
|
|
27
|
+
import os
|
|
28
|
+
import pathlib
|
|
29
|
+
import tomllib
|
|
30
|
+
|
|
31
|
+
root = pathlib.Path(".")
|
|
32
|
+
python_version = tomllib.loads((root / "pyproject.toml").read_text())["project"]["version"]
|
|
33
|
+
npm_version = json.loads((root / "npm/package.json").read_text())["version"]
|
|
34
|
+
expected = os.environ["RELEASE_VERSION"]
|
|
35
|
+
assert python_version == expected, (python_version, expected)
|
|
36
|
+
assert npm_version == expected, (npm_version, expected)
|
|
37
|
+
PY
|
|
38
|
+
- uses: docker/setup-qemu-action@v3
|
|
39
|
+
- uses: docker/setup-buildx-action@v3
|
|
40
|
+
- uses: docker/login-action@v3
|
|
41
|
+
with:
|
|
42
|
+
registry: ghcr.io
|
|
43
|
+
username: ${{ github.actor }}
|
|
44
|
+
password: ${{ secrets.GITHUB_TOKEN }}
|
|
45
|
+
- uses: docker/build-push-action@v6
|
|
46
|
+
with:
|
|
47
|
+
context: .
|
|
48
|
+
file: Dockerfile.witdem
|
|
49
|
+
platforms: linux/amd64,linux/arm64
|
|
50
|
+
push: true
|
|
51
|
+
sbom: true
|
|
52
|
+
provenance: mode=max
|
|
53
|
+
tags: |
|
|
54
|
+
ghcr.io/${{ github.repository_owner }}/witdem-analytics:${{ inputs.version }}
|
|
55
|
+
ghcr.io/${{ github.repository_owner }}/witdem-analytics:sha-${{ github.sha }}
|
|
56
|
+
- name: Compose smoke test published image
|
|
57
|
+
env:
|
|
58
|
+
WITDEM_ANALYTICS_IMAGE: ghcr.io/${{ github.repository_owner }}/witdem-analytics:${{ inputs.version }}
|
|
59
|
+
run: |
|
|
60
|
+
docker compose pull witdem elt-worker dashboard
|
|
61
|
+
docker compose up -d --no-build
|
|
62
|
+
for attempt in $(seq 1 30); do
|
|
63
|
+
curl -fsS http://localhost:4318/readiness && curl -fsS http://localhost:8501/health && exit 0
|
|
64
|
+
sleep 2
|
|
65
|
+
done
|
|
66
|
+
docker compose logs
|
|
67
|
+
exit 1
|
|
68
|
+
- uses: actions/setup-node@v6
|
|
69
|
+
with:
|
|
70
|
+
node-version: "24"
|
|
71
|
+
registry-url: https://registry.npmjs.org
|
|
72
|
+
package-manager-cache: false
|
|
73
|
+
- name: Test npm launcher
|
|
74
|
+
working-directory: npm
|
|
75
|
+
run: |
|
|
76
|
+
npm ci --ignore-scripts
|
|
77
|
+
npm run check
|
|
78
|
+
npm test
|
|
79
|
+
npm pack --dry-run
|
|
80
|
+
- name: Confirm the matching public image is pullable
|
|
81
|
+
run: |
|
|
82
|
+
docker logout ghcr.io
|
|
83
|
+
docker manifest inspect ghcr.io/${{ github.repository_owner }}/witdem-analytics:${{ inputs.version }} >/dev/null
|
|
84
|
+
- name: Publish npm launcher
|
|
85
|
+
working-directory: npm
|
|
86
|
+
run: npm publish --access public
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
name: Release witdem-sdk
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
workflow_dispatch:
|
|
5
|
+
push:
|
|
6
|
+
tags: ["sdk-v*"]
|
|
7
|
+
|
|
8
|
+
permissions:
|
|
9
|
+
contents: read
|
|
10
|
+
id-token: write
|
|
11
|
+
|
|
12
|
+
jobs:
|
|
13
|
+
publish:
|
|
14
|
+
runs-on: ubuntu-latest
|
|
15
|
+
environment: pypi
|
|
16
|
+
defaults:
|
|
17
|
+
run:
|
|
18
|
+
working-directory: witdem-sdk
|
|
19
|
+
steps:
|
|
20
|
+
- uses: actions/checkout@v4
|
|
21
|
+
- uses: actions/setup-python@v5
|
|
22
|
+
with:
|
|
23
|
+
python-version: "3.12"
|
|
24
|
+
- run: python -m pip install build twine
|
|
25
|
+
- run: python -m build
|
|
26
|
+
- run: python -m twine check dist/*
|
|
27
|
+
- name: Smoke-test built wheel
|
|
28
|
+
run: |
|
|
29
|
+
python -m venv /tmp/witdem-sdk-wheel
|
|
30
|
+
/tmp/witdem-sdk-wheel/bin/pip install dist/*.whl
|
|
31
|
+
/tmp/witdem-sdk-wheel/bin/python - <<'PY'
|
|
32
|
+
import json
|
|
33
|
+
from pathlib import Path
|
|
34
|
+
import witdem_sdk
|
|
35
|
+
metadata = json.loads(Path('../compatibility.json').read_text())
|
|
36
|
+
assert witdem_sdk.__version__
|
|
37
|
+
assert witdem_sdk.SEMANTIC_RECORD_PROTOCOL_VERSION == metadata['semantic_record_protocol']
|
|
38
|
+
PY
|
|
39
|
+
- uses: pypa/gh-action-pypi-publish@release/v1
|
|
40
|
+
with:
|
|
41
|
+
packages-dir: witdem-sdk/dist
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
name: Test
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
pull_request:
|
|
5
|
+
push:
|
|
6
|
+
branches: [main]
|
|
7
|
+
|
|
8
|
+
jobs:
|
|
9
|
+
npm-launcher:
|
|
10
|
+
runs-on: ubuntu-latest
|
|
11
|
+
defaults:
|
|
12
|
+
run:
|
|
13
|
+
working-directory: npm
|
|
14
|
+
steps:
|
|
15
|
+
- uses: actions/checkout@v4
|
|
16
|
+
- uses: actions/setup-node@v4
|
|
17
|
+
with:
|
|
18
|
+
node-version: "20"
|
|
19
|
+
cache: npm
|
|
20
|
+
cache-dependency-path: npm/package-lock.json
|
|
21
|
+
- run: npm ci --ignore-scripts
|
|
22
|
+
- run: npm run check
|
|
23
|
+
- run: npm test
|
|
24
|
+
- run: npm pack --dry-run
|
|
25
|
+
- name: Validate the packaged Compose definition
|
|
26
|
+
env:
|
|
27
|
+
WITDEM_IMAGE: ghcr.io/ebrahimisoheil/witdem-analytics:0.2.0
|
|
28
|
+
WITDEM_RECEIVER_PORT: "4318"
|
|
29
|
+
WITDEM_DASHBOARD_PORT: "8501"
|
|
30
|
+
run: docker compose --file compose.yaml config --quiet
|
|
31
|
+
|
|
32
|
+
packages:
|
|
33
|
+
runs-on: ubuntu-latest
|
|
34
|
+
strategy:
|
|
35
|
+
fail-fast: false
|
|
36
|
+
matrix:
|
|
37
|
+
python: ["3.10", "3.11", "3.12", "3.13"]
|
|
38
|
+
steps:
|
|
39
|
+
- uses: actions/checkout@v4
|
|
40
|
+
- uses: astral-sh/setup-uv@v6
|
|
41
|
+
with:
|
|
42
|
+
python-version: ${{ matrix.python }}
|
|
43
|
+
- run: uv sync --all-groups
|
|
44
|
+
- run: uv run pytest -q
|
|
45
|
+
- run: uv run ruff check src tests
|
|
46
|
+
- run: uv run mypy src
|
|
47
|
+
- run: uv sync --project witdem-sdk --all-groups
|
|
48
|
+
- run: uv run pytest -q
|
|
49
|
+
working-directory: witdem-sdk
|
|
50
|
+
- run: uv run ruff check src tests
|
|
51
|
+
working-directory: witdem-sdk
|
|
52
|
+
- run: uv run mypy src
|
|
53
|
+
working-directory: witdem-sdk
|
|
54
|
+
|
|
55
|
+
product-factory:
|
|
56
|
+
runs-on: ubuntu-latest
|
|
57
|
+
defaults:
|
|
58
|
+
run:
|
|
59
|
+
working-directory: examples/product-factory
|
|
60
|
+
steps:
|
|
61
|
+
- uses: actions/checkout@v4
|
|
62
|
+
- uses: astral-sh/setup-uv@v6
|
|
63
|
+
with:
|
|
64
|
+
python-version: "3.12"
|
|
65
|
+
- run: uv sync --all-groups --all-extras
|
|
66
|
+
- name: Install analytics package used by internal experiment tests
|
|
67
|
+
run: uv pip install --python .venv/bin/python -e ../..
|
|
68
|
+
- run: uv run pytest -q
|
|
69
|
+
- run: uv run ruff check src tests
|
|
70
|
+
- run: uv run mypy src
|
|
71
|
+
|
|
72
|
+
sdk-extras:
|
|
73
|
+
runs-on: ubuntu-latest
|
|
74
|
+
strategy:
|
|
75
|
+
fail-fast: false
|
|
76
|
+
matrix:
|
|
77
|
+
extra: [anthropic, openai, langchain, langgraph, haystack, all]
|
|
78
|
+
steps:
|
|
79
|
+
- uses: actions/checkout@v4
|
|
80
|
+
- uses: astral-sh/setup-uv@v6
|
|
81
|
+
with:
|
|
82
|
+
python-version: "3.12"
|
|
83
|
+
- run: uv venv /tmp/witdem-extra
|
|
84
|
+
- run: uv pip install --python /tmp/witdem-extra/bin/python "./witdem-sdk[${{ matrix.extra }}]"
|
|
85
|
+
- name: Import selected integration
|
|
86
|
+
run: |
|
|
87
|
+
case "${{ matrix.extra }}" in
|
|
88
|
+
openai) module=openai_agents ;;
|
|
89
|
+
all) module=anthropic ;;
|
|
90
|
+
*) module="${{ matrix.extra }}" ;;
|
|
91
|
+
esac
|
|
92
|
+
/tmp/witdem-extra/bin/python -c "import witdem_sdk; import witdem_sdk.integrations.${module}"
|
|
93
|
+
|
|
94
|
+
sdk-integrations:
|
|
95
|
+
runs-on: ubuntu-latest
|
|
96
|
+
defaults:
|
|
97
|
+
run:
|
|
98
|
+
working-directory: witdem-sdk
|
|
99
|
+
steps:
|
|
100
|
+
- uses: actions/checkout@v4
|
|
101
|
+
- uses: astral-sh/setup-uv@v6
|
|
102
|
+
with:
|
|
103
|
+
python-version: "3.12"
|
|
104
|
+
- run: uv sync --all-groups --all-extras
|
|
105
|
+
- run: uv run pytest -q tests/test_optional_integrations.py
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
__pycache__/
|
|
2
|
+
*.pyc
|
|
3
|
+
.venv/
|
|
4
|
+
.mypy_cache/
|
|
5
|
+
.ruff_cache/
|
|
6
|
+
.pytest_cache/
|
|
7
|
+
*.duckdb
|
|
8
|
+
/data/backups/
|
|
9
|
+
.env
|
|
10
|
+
.DS_Store
|
|
11
|
+
!data/synthetic-ui-v2/
|
|
12
|
+
!data/synthetic-ui-v2/**
|
|
13
|
+
!data/synthetic-ui-v2/analytics.duckdb
|
|
14
|
+
data/live/
|
|
15
|
+
.claude/
|
|
16
|
+
data/**/.DS_Store
|
|
17
|
+
|
|
18
|
+
# Dashboard contributor build artifacts
|
|
19
|
+
web/node_modules/
|
|
20
|
+
web/*.tsbuildinfo
|
|
21
|
+
web/vite.config.js
|
|
22
|
+
web/vite.config.d.ts
|
|
23
|
+
web/tailwind.config.js
|
|
24
|
+
web/tailwind.config.d.ts
|
|
25
|
+
|
|
26
|
+
# Locally generated live-matrix reports
|
|
27
|
+
examples/product-factory/reports/
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
FROM node:22-slim AS dashboard-build
|
|
2
|
+
|
|
3
|
+
WORKDIR /build/web
|
|
4
|
+
COPY web/package.json web/package-lock.json ./
|
|
5
|
+
RUN npm ci
|
|
6
|
+
COPY web ./
|
|
7
|
+
RUN npm run build
|
|
8
|
+
|
|
9
|
+
FROM python:3.12-slim
|
|
10
|
+
|
|
11
|
+
WORKDIR /app
|
|
12
|
+
|
|
13
|
+
ARG WITDEM_ANALYTICS_REQUIREMENT=.
|
|
14
|
+
|
|
15
|
+
COPY pyproject.toml ./
|
|
16
|
+
COPY README.md ./README.md
|
|
17
|
+
COPY src ./src
|
|
18
|
+
COPY --from=dashboard-build /build/src/witdem/dashboard/static ./src/witdem/dashboard/static
|
|
19
|
+
|
|
20
|
+
RUN pip install --no-cache-dir "${WITDEM_ANALYTICS_REQUIREMENT}"
|
|
21
|
+
|
|
22
|
+
EXPOSE 4318
|
|
23
|
+
|
|
24
|
+
HEALTHCHECK --interval=30s --timeout=3s --start-period=5s \
|
|
25
|
+
CMD python -c "import urllib.request as u; u.urlopen('http://localhost:4318/health', timeout=2)" || exit 1
|
|
26
|
+
|
|
27
|
+
CMD ["witdem", "serve", "--host", "0.0.0.0", "--port", "4318"]
|
|
@@ -0,0 +1,218 @@
|
|
|
1
|
+
Metadata-Version: 2.5
|
|
2
|
+
Name: witdem-analytics
|
|
3
|
+
Version: 0.2.0
|
|
4
|
+
Summary: Runtime analytics for agent applications using OpenTelemetry, with optional business semantics through the Witdem SDK.
|
|
5
|
+
Requires-Python: >=3.10
|
|
6
|
+
Requires-Dist: duckdb<2,>=1.2
|
|
7
|
+
Requires-Dist: duckle==0.5.11
|
|
8
|
+
Requires-Dist: fastapi<1,>=0.115
|
|
9
|
+
Requires-Dist: filelock<4,>=3.16
|
|
10
|
+
Requires-Dist: httpx<1,>=0.27
|
|
11
|
+
Requires-Dist: opentelemetry-api<2,>=1.27
|
|
12
|
+
Requires-Dist: opentelemetry-exporter-otlp-proto-http<2,>=1.27
|
|
13
|
+
Requires-Dist: opentelemetry-proto<2,>=1.27
|
|
14
|
+
Requires-Dist: opentelemetry-sdk<2,>=1.27
|
|
15
|
+
Requires-Dist: platformdirs<5,>=4.3
|
|
16
|
+
Requires-Dist: pydantic<3,>=2.10
|
|
17
|
+
Requires-Dist: pyyaml<7,>=6.0
|
|
18
|
+
Requires-Dist: uvicorn[standard]<1,>=0.34
|
|
19
|
+
Description-Content-Type: text/markdown
|
|
20
|
+
|
|
21
|
+
<div align="center">
|
|
22
|
+
|
|
23
|
+
# Witdem
|
|
24
|
+
|
|
25
|
+
**Analytics for AI agents and multi-step AI applications.**
|
|
26
|
+
|
|
27
|
+
Tracing tells you what executed. Witdem connects those executions to application outcomes: which paths ran, what they cost, where they failed, and whether they achieved the product goal you defined.
|
|
28
|
+
|
|
29
|
+
[Get started](docs/getting-started.md) · [YAML contracts](docs/contract-tutorial.md) · [Haystack](docs/integrations/haystack.md) · [Frameworks](#integration-status) · [Providers](docs/providers.md) · [Troubleshooting](docs/troubleshooting.md)
|
|
30
|
+
|
|
31
|
+
</div>
|
|
32
|
+
|
|
33
|
+
## First run
|
|
34
|
+
|
|
35
|
+
Start the local receiver, ELT worker, and dashboard:
|
|
36
|
+
|
|
37
|
+
```bash
|
|
38
|
+
npx -y witdem@0.2.0 up
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
That pulls the version-matched container, starts all three services, waits for
|
|
42
|
+
them to become healthy, and opens `http://localhost:8501`. Docker with Compose
|
|
43
|
+
is the only prerequisite. Data persists across `down` and package upgrades.
|
|
44
|
+
|
|
45
|
+
```bash
|
|
46
|
+
npx -y witdem@0.2.0 status
|
|
47
|
+
npx -y witdem@0.2.0 logs
|
|
48
|
+
npx -y witdem@0.2.0 down
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
Add the SDK to an existing Haystack 3 project from the checkout:
|
|
52
|
+
|
|
53
|
+
```bash
|
|
54
|
+
python -m pip install -e "/path/to/Witdem-Analytics/witdem-sdk[haystack]"
|
|
55
|
+
export WITDEM_ENDPOINT=http://localhost:4318
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
Wrap the pipeline once. Its existing `run`, `run_async`, and `run_async_generator` calls stay unchanged:
|
|
59
|
+
|
|
60
|
+
```python
|
|
61
|
+
from witdem_sdk.integrations.haystack import instrument
|
|
62
|
+
|
|
63
|
+
pipeline = instrument(build_pipeline())
|
|
64
|
+
result = pipeline.run(data)
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
Add `.witdem/witdem.yaml` to describe what a useful result means:
|
|
68
|
+
|
|
69
|
+
```yaml
|
|
70
|
+
version: 1
|
|
71
|
+
service:
|
|
72
|
+
name: support-agent
|
|
73
|
+
runtime: haystack
|
|
74
|
+
telemetry:
|
|
75
|
+
capture_content: false
|
|
76
|
+
contracts:
|
|
77
|
+
- name: answer
|
|
78
|
+
mode: expression
|
|
79
|
+
artifact:
|
|
80
|
+
name: Support answer
|
|
81
|
+
valid:
|
|
82
|
+
non_empty: $.answer
|
|
83
|
+
decision:
|
|
84
|
+
name: Result validity
|
|
85
|
+
expected: true
|
|
86
|
+
observed: $.witdem.artifact_valid
|
|
87
|
+
product_goal:
|
|
88
|
+
name: Useful answer returned
|
|
89
|
+
achieved: $.witdem.artifact_valid
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
Run the application normally. The execution and its business result appear at **http://localhost:8501**.
|
|
93
|
+
|
|
94
|
+
> `witdem-sdk` 0.2.0 is not yet published to the package index. The source-checkout command above is the verified installation path for this release. Publishing the package is the remaining installation launch blocker.
|
|
95
|
+
|
|
96
|
+
## What you get
|
|
97
|
+
|
|
98
|
+
- Actual execution paths, branches, loops, retries, tools, model calls, and failures
|
|
99
|
+
- Per-run latency, token usage, and cost when provider/model/usage evidence is sufficient
|
|
100
|
+
- Application outcomes and product-goal success defined by your application
|
|
101
|
+
- Provider and model comparisons using attributable time, usage, cost, and quality
|
|
102
|
+
- Workflow/path analytics and run-linked issue investigation
|
|
103
|
+
- Local DuckDB storage and a self-hosted dashboard; prompt and response capture is off by default
|
|
104
|
+
|
|
105
|
+
Witdem does not infer business success from a completed LLM call. Framework instrumentation records what happened technically; `.witdem/witdem.yaml` explains what the final result means.
|
|
106
|
+
|
|
107
|
+
## Integration status
|
|
108
|
+
|
|
109
|
+
Statuses reflect current implementation and test evidence, not roadmap intent.
|
|
110
|
+
|
|
111
|
+
| Integration | Status | Verified surface |
|
|
112
|
+
| --- | --- | --- |
|
|
113
|
+
| [Haystack 3](docs/integrations/haystack.md) | **Stable** | Pipelines, agents, components, provider calls, loops, parallel branches, `run`, `run_async`, async generators |
|
|
114
|
+
| [LangGraph](docs/integrations/langgraph.md) | **Beta** | Compiled graphs, nodes, tools, models, errors, sync/async invocation and streaming |
|
|
115
|
+
| [LangChain](docs/integrations/langchain.md) | **Beta** | Runnables, chains, chat/LLM calls, tools, retrievers, sync/async invocation and streaming |
|
|
116
|
+
| [Native Python](docs/integrations/native-python.md) | **Supported** | Execution, operation, model, tool, decision, evaluation, outcome, and metric primitives |
|
|
117
|
+
| [OpenAI Agents](docs/integrations/openai-agents.md) | **Beta** | Native trace processor, agents, generations, tools, handoffs, sync/async workloads |
|
|
118
|
+
| [Anthropic Messages and Claude Agent SDK](docs/integrations/anthropic.md) | **Beta** | Messages calls, usage, tool-use IDs, multi-turn workloads, Claude Agent message streams |
|
|
119
|
+
| [Hugging Face smolagents](docs/integrations/smolagents.md) | **Beta** | Official OpenInference agent, step, model, and tool spans; sync and streaming execution |
|
|
120
|
+
| [LiteLLM](docs/integrations/litellm.md) | **Beta** | SDK callback and proxy OTLP paths, provider/model usage, reported cost, failures, routing metadata |
|
|
121
|
+
| [OpenRouter](docs/providers/openrouter.md) | **Beta** | OpenAI-compatible sync/async and streaming calls, selected provider, route attempts, authoritative cost |
|
|
122
|
+
| Generic provider calls | **Experimental** | Sync/async callable wrapper with explicit provider/model and observed result metadata |
|
|
123
|
+
| Standard OTLP/HTTP | **Supported** | Generic OpenTelemetry, OTel GenAI, and OpenInference evidence |
|
|
124
|
+
|
|
125
|
+
See [`compatibility.json`](compatibility.json) for machine-readable version constraints and [Providers](docs/providers.md) for the difference between native, framework-observed, and generic support.
|
|
126
|
+
|
|
127
|
+
## Providers
|
|
128
|
+
|
|
129
|
+
Witdem currently has verified paths for:
|
|
130
|
+
|
|
131
|
+
- [OpenAI](docs/providers/openai.md) and [Azure OpenAI](docs/providers/azure-openai.md)
|
|
132
|
+
- [Anthropic](docs/providers/anthropic.md), including Claude Agent SDK telemetry
|
|
133
|
+
- [DeepSeek](docs/providers/deepseek.md)
|
|
134
|
+
- [Mistral](docs/providers/mistral.md)
|
|
135
|
+
- [Amazon Bedrock](docs/providers/bedrock.md)
|
|
136
|
+
- [Google Vertex AI](docs/providers/vertex-ai.md)
|
|
137
|
+
- [Ollama](docs/providers/ollama.md)
|
|
138
|
+
- [Cohere](docs/providers/cohere.md) (structurally tested, not live-validated)
|
|
139
|
+
- [OpenRouter](docs/providers/openrouter.md), including selected upstream provider and fallback metadata
|
|
140
|
+
- Hugging Face inference through [smolagents](docs/integrations/smolagents.md) or [LiteLLM](docs/integrations/litellm.md)
|
|
141
|
+
|
|
142
|
+
OpenAI and Anthropic have dedicated SDK integrations. Haystack observes the generator actually used at each model boundary. The remaining provider examples use standard GenAI OpenTelemetry attributes or `witdem_sdk.integrations.generic`; this is explicit in every provider guide.
|
|
143
|
+
|
|
144
|
+
Cost is not assumed from a provider name. Witdem uses provider-reported money when present, or the versioned server catalog when provider, model, and token usage match a catalog entry. Unknown prices remain **Not measured** with a diagnostic reason.
|
|
145
|
+
|
|
146
|
+
## Parallel and asynchronous execution
|
|
147
|
+
|
|
148
|
+
When sibling spans overlap, Witdem preserves the observed fan-out and fan-in rather than flattening them into a false sequence:
|
|
149
|
+
|
|
150
|
+
```text
|
|
151
|
+
┌─ semantic retriever ─┐
|
|
152
|
+
execution ───┤ ├─ answer
|
|
153
|
+
└─ keyword retriever ──┘
|
|
154
|
+
```
|
|
155
|
+
|
|
156
|
+
The runnable [Haystack parallel pipeline](examples/haystack/pipeline/README.md) demonstrates this with two concurrent retrievers and an OpenAI answer component.
|
|
157
|
+
|
|
158
|
+
## Self-hosting
|
|
159
|
+
|
|
160
|
+
The npm launcher is the recommended local backend path. It is deliberately a
|
|
161
|
+
small, dependency-free Docker launcher rather than a second implementation of
|
|
162
|
+
Witdem. It never runs an npm `postinstall` script.
|
|
163
|
+
|
|
164
|
+
| Service | Address | Purpose |
|
|
165
|
+
| --- | --- | --- |
|
|
166
|
+
| Dashboard | `http://localhost:8501` | Overview, runs, compare, workflows, and issues |
|
|
167
|
+
| Receiver | `http://localhost:4318` | OTLP/HTTP and SDK record ingestion |
|
|
168
|
+
| ELT worker | internal | Duckle transformation into dashboard-ready DuckDB tables |
|
|
169
|
+
|
|
170
|
+
```bash
|
|
171
|
+
npx -y witdem@0.2.0 status
|
|
172
|
+
curl http://localhost:4318/readiness
|
|
173
|
+
curl http://localhost:8501/health
|
|
174
|
+
```
|
|
175
|
+
|
|
176
|
+
For source development, clone the repository and run `docker compose up -d`.
|
|
177
|
+
See [Running Witdem with npx](docs/npm-launcher.md) for ports, lifecycle, image
|
|
178
|
+
pinning, and troubleshooting.
|
|
179
|
+
|
|
180
|
+
The Python-only development path is also available:
|
|
181
|
+
|
|
182
|
+
```bash
|
|
183
|
+
uv sync
|
|
184
|
+
uv run witdem dev --open
|
|
185
|
+
```
|
|
186
|
+
|
|
187
|
+
## Documentation
|
|
188
|
+
|
|
189
|
+
- [Getting started](docs/getting-started.md)
|
|
190
|
+
- [Running Witdem with npx](docs/npm-launcher.md)
|
|
191
|
+
- [Concepts: tracing and business meaning](docs/concepts.md)
|
|
192
|
+
- [Tutorial: defining a YAML contract](docs/contract-tutorial.md)
|
|
193
|
+
- [YAML configuration](docs/configuration.md)
|
|
194
|
+
- [Haystack](docs/integrations/haystack.md)
|
|
195
|
+
- [LangGraph](docs/integrations/langgraph.md)
|
|
196
|
+
- [LangChain](docs/integrations/langchain.md)
|
|
197
|
+
- [Native/custom Python](docs/integrations/native-python.md)
|
|
198
|
+
- [OpenAI Agents](docs/integrations/openai-agents.md)
|
|
199
|
+
- [Anthropic and Claude Agent](docs/integrations/anthropic.md)
|
|
200
|
+
- [Provider support](docs/providers.md)
|
|
201
|
+
- [Pricing catalog and automated refresh](docs/pricing.md)
|
|
202
|
+
- [Dashboard](docs/dashboard.md)
|
|
203
|
+
- [Troubleshooting](docs/troubleshooting.md)
|
|
204
|
+
- [Examples](docs/examples.md)
|
|
205
|
+
- [Operations](docs/operations.md)
|
|
206
|
+
- [Development and contributing](docs/development.md)
|
|
207
|
+
|
|
208
|
+
## Built with
|
|
209
|
+
|
|
210
|
+
<table>
|
|
211
|
+
<tr>
|
|
212
|
+
<td align="center" width="33%"><img src="docs/assets/duckdb.svg" alt="DuckDB" width="180"><br>Local analytics storage</td>
|
|
213
|
+
<td align="center" width="33%"><img src="docs/assets/duckle.png" alt="Duckle" width="105"><br>Raw-to-serving transformation</td>
|
|
214
|
+
<td align="center" width="33%"><img src="docs/assets/tanstack.svg" alt="TanStack" width="180"><br>Dashboard routing, queries, and tables</td>
|
|
215
|
+
</tr>
|
|
216
|
+
</table>
|
|
217
|
+
|
|
218
|
+
Witdem is independent of these projects. Their names and unmodified marks identify the technologies used and do not imply endorsement.
|