langfuse-agent 2.3.4__tar.gz → 2.3.6__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.
Files changed (88) hide show
  1. {langfuse_agent-2.3.4/langfuse_agent.egg-info → langfuse_agent-2.3.6}/PKG-INFO +3 -9
  2. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/README.md +0 -2
  3. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/__init__.py +15 -0
  4. langfuse_agent-2.3.6/langfuse_agent/__main__.py +4 -0
  5. langfuse_agent-2.3.6/langfuse_agent/connector_sources.py +180 -0
  6. langfuse_agent-2.3.6/langfuse_agent/mcp_server.py +37 -0
  7. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/ontology/certification.json +6 -6
  8. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/ontology/mappings/source.yaml +1 -1
  9. langfuse_agent-2.3.6/langfuse_agent/skills/langfuse-agent-development/SKILL.md +118 -0
  10. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6/langfuse_agent.egg-info}/PKG-INFO +3 -9
  11. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent.egg-info/SOURCES.txt +3 -5
  12. langfuse_agent-2.3.6/langfuse_agent.egg-info/entry_points.txt +8 -0
  13. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent.egg-info/requires.txt +1 -7
  14. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/pyproject.toml +16 -13
  15. langfuse_agent-2.3.6/tests/test_api_parity_gate.py +49 -0
  16. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/tests/test_fleet_name.py +1 -1
  17. langfuse_agent-2.3.6/tests/test_langfuse_development_skill.py +54 -0
  18. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/tests/test_mcp_brute_force.py +0 -72
  19. langfuse_agent-2.3.6/tests/test_pages_workflow.py +40 -0
  20. langfuse_agent-2.3.6/tests/test_release_version.py +23 -0
  21. langfuse_agent-2.3.4/langfuse_agent/__main__.py +0 -6
  22. langfuse_agent-2.3.4/langfuse_agent/connector_sources.py +0 -332
  23. langfuse_agent-2.3.4/langfuse_agent/connectors/__init__.py +0 -0
  24. langfuse_agent-2.3.4/langfuse_agent/mcp_server.py +0 -103
  25. langfuse_agent-2.3.4/langfuse_agent/prompts/__init__.py +0 -0
  26. langfuse_agent-2.3.4/langfuse_agent/skills/__init__.py +0 -0
  27. langfuse_agent-2.3.4/langfuse_agent.egg-info/entry_points.txt +0 -14
  28. langfuse_agent-2.3.4/tests/test_api_parity_gate.py +0 -58
  29. langfuse_agent-2.3.4/tests/test_default_content_surfaces.py +0 -43
  30. langfuse_agent-2.3.4/tests/test_mcp_server.py +0 -51
  31. langfuse_agent-2.3.4/tests/test_release_version.py +0 -38
  32. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/LICENSE +0 -0
  33. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/MANIFEST.in +0 -0
  34. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/build_backend.py +0 -0
  35. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/api/__init__.py +0 -0
  36. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/api/api_client_annotation_queues.py +0 -0
  37. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/api/api_client_base.py +0 -0
  38. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/api/api_client_datasets.py +0 -0
  39. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/api/api_client_management.py +0 -0
  40. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/api/api_client_observability.py +0 -0
  41. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/api/api_client_prompts_models.py +0 -0
  42. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/api_client.py +0 -0
  43. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/auth.py +0 -0
  44. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/dependency-license-catalog.json +0 -0
  45. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/kg_ingest.py +0 -0
  46. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/langfuse_models.py +0 -0
  47. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/main_agent.md +0 -0
  48. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/mcp/__init__.py +0 -0
  49. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/mcp_config.json +0 -0
  50. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/ontology/__init__.py +0 -0
  51. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/ontology/fixtures/records.json +0 -0
  52. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/ontology/langfuse.ttl +0 -0
  53. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/ontology/migrations/manifest.json +0 -0
  54. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/ontology/shapes/connector.shacl.ttl +0 -0
  55. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/prompts/observability_specialist.json +0 -0
  56. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/runtime_posture.py +0 -0
  57. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/skills/langfuse-agent-operations/SKILL.md +0 -0
  58. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/skills/langfuse-agent-operations/agents/openai.yaml +0 -0
  59. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/skills/langfuse-agent-operations/references/catalog.md +0 -0
  60. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/skills/langfuse-eval-datasets/SKILL.md +0 -0
  61. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/skills/langfuse-eval-datasets/WORKFLOW.md +0 -0
  62. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/skills/langfuse-prompt-management/SKILL.md +0 -0
  63. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/skills/langfuse-prompt-management/WORKFLOW.md +0 -0
  64. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/skills/langfuse-trace-analytics/SKILL.md +0 -0
  65. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/skills/langfuse-trace-analytics/WORKFLOW.md +0 -0
  66. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/tools/__init__.py +0 -0
  67. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/tools/datasets.py +0 -0
  68. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/tools/kg.py +0 -0
  69. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/tools/management.py +0 -0
  70. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/tools/observability.py +0 -0
  71. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/tools/prompts.py +0 -0
  72. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent/trace_projection.py +0 -0
  73. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent.egg-info/dependency_links.txt +0 -0
  74. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/langfuse_agent.egg-info/top_level.txt +0 -0
  75. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/requirements.txt +0 -0
  76. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/setup.cfg +0 -0
  77. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/tests/test_auth.py +0 -0
  78. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/tests/test_documentation_privacy.py +0 -0
  79. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/tests/test_init.py +0 -0
  80. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/tests/test_init_dynamics.py +0 -0
  81. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/tests/test_kg_ingest.py +0 -0
  82. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/tests/test_kg_tool.py +0 -0
  83. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/tests/test_langfuse_api.py +0 -0
  84. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/tests/test_langfuse_models.py +0 -0
  85. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/tests/test_placeholder.py +0 -0
  86. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/tests/test_tools_dispatch_characterization.py +0 -0
  87. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/tests/test_trace_projection.py +0 -0
  88. {langfuse_agent-2.3.4 → langfuse_agent-2.3.6}/tests/test_wheel_privacy.py +0 -0
@@ -1,8 +1,8 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: langfuse-agent
3
- Version: 2.3.4
3
+ Version: 2.3.6
4
4
  Summary: Agent for interacting with Langfuse Observability API
5
- Author: Project Contributors
5
+ Author: Repository Maintainers
6
6
  License-Expression: MIT
7
7
  Classifier: Development Status :: 4 - Beta
8
8
  Classifier: Environment :: Console
@@ -11,13 +11,9 @@ Classifier: Programming Language :: Python :: 3
11
11
  Requires-Python: >=3.12
12
12
  Description-Content-Type: text/markdown
13
13
  License-File: LICENSE
14
- Requires-Dist: agent-connector-sdk[mcp]<1.0.0,>=0.4.1
14
+ Requires-Dist: agent-connector-sdk[mcp]<0.6.0,>=0.5.4
15
15
  Requires-Dist: langfuse<5,>=4
16
16
  Requires-Dist: requests>=2.34.2
17
- Provides-Extra: mcp
18
- Requires-Dist: agent-connector-sdk[mcp]<1.0.0,>=0.4.1; extra == "mcp"
19
- Provides-Extra: all
20
- Requires-Dist: agent-connector-sdk[mcp]<1.0.0,>=0.4.1; extra == "all"
21
17
  Provides-Extra: test
22
18
  Requires-Dist: pytest-xdist>=3.8.0; extra == "test"
23
19
  Requires-Dist: pytest>=9.1.1; extra == "test"
@@ -50,8 +46,6 @@ Dynamic: license-file
50
46
  ![PyPI - Wheel](https://img.shields.io/pypi/wheel/langfuse-agent)
51
47
  ![PyPI - Implementation](https://img.shields.io/pypi/implementation/langfuse-agent)
52
48
 
53
- *Version: 2.3.4*
54
-
55
49
  > **Documentation** — Installation, deployment, usage across the API, CLI, and MCP
56
50
  > interfaces, and guidance for provisioning the Langfuse platform are maintained in
57
51
  > the [official documentation](https://knuckles-team.github.io/langfuse-agent/).
@@ -20,8 +20,6 @@
20
20
  ![PyPI - Wheel](https://img.shields.io/pypi/wheel/langfuse-agent)
21
21
  ![PyPI - Implementation](https://img.shields.io/pypi/implementation/langfuse-agent)
22
22
 
23
- *Version: 2.3.4*
24
-
25
23
  > **Documentation** — Installation, deployment, usage across the API, CLI, and MCP
26
24
  > interfaces, and guidance for provisioning the Langfuse platform are maintained in
27
25
  > the [official documentation](https://knuckles-team.github.io/langfuse-agent/).
@@ -91,3 +91,18 @@ def __getattr__(name: str) -> Any:
91
91
 
92
92
  def __dir__() -> list[str]:
93
93
  return sorted(list(globals().keys()) + __all__)
94
+
95
+
96
+ from agent_connector_sdk.connector import Connector
97
+
98
+ from langfuse_agent.api_client import LangfuseApi
99
+ from langfuse_agent.auth import get_client
100
+
101
+ connector = Connector(
102
+ api=LangfuseApi,
103
+ get_client=get_client,
104
+ tools="langfuse_agent.mcp_server",
105
+ instructions="langfuse-agent MCP Server — Condensed Action-Routed Tools.",
106
+ )
107
+
108
+ __all__ = ["connector"]
@@ -0,0 +1,4 @@
1
+ from agent_connector_sdk import run
2
+
3
+ if __name__ == "__main__":
4
+ run()
@@ -0,0 +1,180 @@
1
+ """Data sources of this connector, declared by tool name (generated by connector-ontology-map migrate).
2
+
3
+ Served live as ``connector://resources``. Regenerate by editing the declarations, not the tools.
4
+ """
5
+
6
+ # ruff: noqa: E501
7
+ from __future__ import annotations
8
+
9
+ from typing import Any
10
+
11
+ from agent_connector_sdk.ingest.live_declaration import source_meta
12
+
13
+ SOURCES: tuple[Any, ...] = (
14
+ source_meta(
15
+ tool="langfuse_sessions_list",
16
+ source_id="langfuse-sessions",
17
+ record_type="Session",
18
+ id_field="id",
19
+ cursor_field="createdAt",
20
+ page_param="page",
21
+ page_size_param="limit",
22
+ pagination="page",
23
+ preset={
24
+ "doc_type": "session",
25
+ "metadata_fields": [
26
+ "createdAt",
27
+ "environment",
28
+ ],
29
+ "page_kind": "number",
30
+ "params_style": "args",
31
+ },
32
+ records_path="data",
33
+ server="langfuse-mcp",
34
+ text_field="id",
35
+ title_field="id",
36
+ ),
37
+ source_meta(
38
+ tool="langfuse_trace_list",
39
+ source_id="langfuse-traces",
40
+ record_type="Trace",
41
+ id_field="id",
42
+ cursor_field="timestamp",
43
+ page_param="page",
44
+ page_size_param="limit",
45
+ pagination="page",
46
+ preset={
47
+ "doc_type": "trace",
48
+ "metadata_fields": [
49
+ "timestamp",
50
+ "release",
51
+ "version",
52
+ "environment",
53
+ "tags",
54
+ ],
55
+ "page_kind": "number",
56
+ "params_style": "args",
57
+ },
58
+ records_path="data",
59
+ server="langfuse-mcp",
60
+ text_field="name",
61
+ title_field="name",
62
+ ),
63
+ )
64
+
65
+ SCHEMA_VERSION = 2
66
+
67
+ FIELD_SETS: dict[str, dict[str, str]] = {
68
+ "fields_1": {
69
+ "dataType": "xsd:string",
70
+ "endTime": "xsd:dateTime",
71
+ "environment": "xsd:string",
72
+ "latency": "xsd:decimal",
73
+ "level": "xsd:string",
74
+ "modelName": "xsd:string",
75
+ "observationType": "xsd:string",
76
+ "promptVersion": "xsd:integer",
77
+ "release": "xsd:string",
78
+ "scoreValue": "xsd:string",
79
+ "startTime": "xsd:dateTime",
80
+ "timestamp": "xsd:dateTime",
81
+ "totalCost": "xsd:decimal",
82
+ "totalTokens": "xsd:integer",
83
+ },
84
+ }
85
+
86
+ SCHEMA_MAPPINGS: dict[str, Any] = {
87
+ "Dataset": {
88
+ "field_sets": ["fields_1"],
89
+ "ontology_class": "Dataset",
90
+ },
91
+ "DatasetRun": {
92
+ "field_sets": ["fields_1"],
93
+ "ontology_class": "Dataset",
94
+ },
95
+ "Generation": {
96
+ "field_sets": ["fields_1"],
97
+ "ontology_class": "Observation",
98
+ },
99
+ "Model": {
100
+ "field_sets": ["fields_1"],
101
+ "ontology_class": None,
102
+ },
103
+ "Observation": {
104
+ "field_sets": ["fields_1"],
105
+ "ontology_class": None,
106
+ },
107
+ "Prompt": {
108
+ "field_sets": ["fields_1"],
109
+ "ontology_class": None,
110
+ },
111
+ "Score": {
112
+ "field_sets": ["fields_1"],
113
+ "ontology_class": None,
114
+ },
115
+ "ScoreConfig": {
116
+ "field_sets": ["fields_1"],
117
+ "ontology_class": None,
118
+ },
119
+ "Session": {
120
+ "field_sets": ["fields_1"],
121
+ "ontology_class": None,
122
+ },
123
+ "Trace": {
124
+ "field_sets": ["fields_1"],
125
+ "ontology_class": None,
126
+ },
127
+ }
128
+
129
+ RESOURCES: tuple[dict[str, str], ...] = (
130
+ {
131
+ "id_prefix": "dataset",
132
+ "label": "Dataset",
133
+ "name": "Dataset",
134
+ },
135
+ {
136
+ "id_prefix": "datasetrun",
137
+ "label": "Dataset Run",
138
+ "name": "DatasetRun",
139
+ },
140
+ {
141
+ "id_prefix": "generation",
142
+ "label": "Generation",
143
+ "name": "Generation",
144
+ },
145
+ {
146
+ "id_prefix": "model",
147
+ "label": "Model",
148
+ "name": "Model",
149
+ },
150
+ {
151
+ "id_prefix": "observation",
152
+ "label": "Observation",
153
+ "name": "Observation",
154
+ },
155
+ {
156
+ "id_prefix": "prompt",
157
+ "label": "Prompt",
158
+ "name": "Prompt",
159
+ },
160
+ {
161
+ "id_prefix": "score",
162
+ "label": "Score",
163
+ "name": "Score",
164
+ },
165
+ {
166
+ "id_prefix": "scoreconfig",
167
+ "label": "Score Config",
168
+ "name": "ScoreConfig",
169
+ },
170
+ {
171
+ "id_prefix": "session",
172
+ "label": "Session",
173
+ "name": "Session",
174
+ },
175
+ {
176
+ "id_prefix": "trace",
177
+ "label": "Trace",
178
+ "name": "Trace",
179
+ },
180
+ )
@@ -0,0 +1,37 @@
1
+ #!/usr/bin/python
2
+ """Langfuse MCP Server.
3
+
4
+ _1.0 — Langfuse MCP Integration
5
+ """
6
+
7
+ import warnings
8
+
9
+ # Filter RequestsDependencyWarning early to prevent log spam
10
+ with warnings.catch_warnings():
11
+ warnings.simplefilter("ignore")
12
+ try:
13
+ from requests.exceptions import RequestsDependencyWarning
14
+
15
+ warnings.filterwarnings("ignore", category=RequestsDependencyWarning)
16
+ except ImportError:
17
+ pass
18
+
19
+ warnings.filterwarnings("ignore", message=".*urllib3.*or chardet.*")
20
+ warnings.filterwarnings("ignore", message=".*urllib3.*or charset_normalizer.*")
21
+
22
+
23
+ from langfuse_agent.tools.datasets import register_langfuse_datasets_tools
24
+ from langfuse_agent.tools.kg import register_langfuse_kg_tools
25
+ from langfuse_agent.tools.management import register_langfuse_management_tools
26
+ from langfuse_agent.tools.observability import register_langfuse_observability_tools
27
+ from langfuse_agent.tools.prompts import register_langfuse_prompts_models_tools
28
+
29
+ # Re-exported so register_tool_surface(tools_module=...) auto-discovers them as
30
+ # module attributes (and ruff treats the imports as used).
31
+ __all__ = [
32
+ "register_langfuse_datasets_tools",
33
+ "register_langfuse_kg_tools",
34
+ "register_langfuse_management_tools",
35
+ "register_langfuse_observability_tools",
36
+ "register_langfuse_prompts_models_tools",
37
+ ]
@@ -1,9 +1,9 @@
1
1
  {
2
- "api_version": "arbora.io/v1",
2
+ "api_version": "graphos.io/v1",
3
3
  "artifacts": {
4
4
  "langfuse_agent/ontology/fixtures/records.json": "45426db59590ddb6e6f72b2296ceefd87236209488199ca4ab36f700f5e08df2",
5
- "langfuse_agent/ontology/langfuse.ttl": "443ac809e5801ca6bc88a600c4926e0373f26261eac132860794e0751a01a185",
6
- "langfuse_agent/ontology/mappings/source.yaml": "6ef844f6a5dedc4ab9362bddc19d4880b0206bd1bbe5d39cfb08b585a7e987b2",
5
+ "langfuse_agent/ontology/langfuse.ttl": "ccf067bee1e910b709617779e3e99313f30e3573b9c2a6f5df5e760565f6727e",
6
+ "langfuse_agent/ontology/mappings/source.yaml": "d9345cdf9d901dc3163519aff275d8fcb04168bd860b118f98ccdfc30d4877b6",
7
7
  "langfuse_agent/ontology/migrations/manifest.json": "abb14bd6b4428d8365cc71c06dd61cb9ece43f0153d2a59b9b2285328bcf66b5",
8
8
  "langfuse_agent/ontology/shapes/connector.shacl.ttl": "ca61d94426ce3e3e7d773f1dcb7f3086b0f9e5694f444721df1798e147a9ba01"
9
9
  },
@@ -15,11 +15,11 @@
15
15
  "synthetic_fixture_contract": "passed"
16
16
  },
17
17
  "compatibility": {
18
- "agent_connector_sdk": ">=2.5.0,<3",
18
+ "agent_utilities": ">=2.5.0,<3",
19
19
  "bundle_schema": "2",
20
20
  "epistemic_graph": ">=2.27.0,<3"
21
21
  },
22
- "connector": "langfuse-mcp",
22
+ "connector": "langfuse-agent",
23
23
  "kind": "ConnectorSourceAttestation",
24
24
  "live_certified": false,
25
25
  "mode": "offline-source",
@@ -29,5 +29,5 @@
29
29
  "signer": "UNSIGNED-PREVIEW",
30
30
  "signing_public_key": "",
31
31
  "status": "source-validated",
32
- "validated_at": "2026-08-26T13:42:55Z"
32
+ "validated_at": "2026-10-27T03:58:34Z"
33
33
  }
@@ -1,5 +1,5 @@
1
1
  schema_version: '1'
2
- connector: langfuse-agent
2
+ connector: langfuse-mcp
3
3
  ontology_source: langfuse
4
4
  sync:
5
5
  - preset: langfuse-sessions
@@ -0,0 +1,118 @@
1
+ ---
2
+ name: langfuse-agent-development
3
+ skill_type: skill
4
+ domain: development
5
+ description: >-
6
+ Develop, test, gate, and release the langfuse-agent connector. Use this skill
7
+ when changing Langfuse API mappings, governed MCP tools, authentication,
8
+ knowledge-graph ingestion, packaged content, or repository gates.
9
+ license: MIT
10
+ tags: [langfuse, observability, development, connector, test, gates]
11
+ tier: repository
12
+ metadata:
13
+ author: Genius
14
+ version: '0.1.0'
15
+ ---
16
+
17
+ # langfuse-agent development
18
+
19
+ This repository owns the Langfuse API facade, the governed MCP tool surface,
20
+ authentication boundary, typed graph-ingestion mappings, and packaged connector
21
+ content. Shared connector contracts, transports, TLS profiles, and credential
22
+ helpers belong to `agent-connector-sdk`; admission, serving, and durable graph
23
+ state belong to their owning repositories. Read `AGENTS.md` before changing
24
+ code. Keep credentials, private endpoints, tenant data, and customer records out
25
+ of source, logs, fixtures, and skill content.
26
+
27
+ ## Rapid delivery: the 5-minute contract
28
+
29
+ Specs are already designed. Deliver small, reviewable slices and cite the
30
+ owning spec row in the commit trailer.
31
+
32
+ - Find the owning row first with `git grep -n "<term>" -- specs` and extend the
33
+ existing spec before adding requirement text. Generated `specs/*/status.json`
34
+ files come from the shared hooks; never hand-edit them.
35
+ - Reuse the `Connector` in `langfuse_agent/__init__.py`, the `LangfuseApi`
36
+ facade in `langfuse_agent/api_client.py`, the API modules under
37
+ `langfuse_agent/api/`, and the registered tools in `langfuse_agent/tools/`
38
+ plus `langfuse_agent/mcp_server.py`. Do not create a second API, MCP,
39
+ authentication, or transport plane.
40
+ - Preserve `LANGFUSE_BASE_URL`, `LANGFUSE_HOST`, `LANGFUSE_PUBLIC_KEY`,
41
+ `LANGFUSE_SECRET_KEY`, the `LANGFUSE_*_REF` credential and TLS settings,
42
+ and `LANGFUSE_PERSISTENCE_HMAC_KEY_REF` handling at the existing
43
+ `langfuse_agent/auth.py` and `langfuse_agent/kg_ingest.py` boundaries. Use
44
+ the SDK TLS and credential resolvers; never print credentials or add a
45
+ verification bypass.
46
+ - Keep the `MCP_TOOL_MODE` surface and the existing Langfuse tool toggle
47
+ settings aligned with `langfuse_agent/mcp_server.py` and the generated README
48
+ inventory. Mock provider HTTP responses in tests; never call a live Langfuse
49
+ project or use live credentials in a gate.
50
+ - Preserve typed, privacy-bounded ingestion through
51
+ `agent_connector_sdk.ingest`, source declarations in
52
+ `langfuse_agent/connector_sources.py`, and neutral ontology assets under
53
+ `langfuse_agent/ontology/`. Do not bypass the shared ingestion facade.
54
+ - Keep `skills/**`, `ontology/**`, `connectors/**`, prompts, and
55
+ `mcp_config.json` coherent with the `langfuse_agent` package data and the
56
+ `langfuse-mcp` project script. Every delivered
57
+ requirement needs a bound focused test.
58
+
59
+ ## Setup and gates
60
+
61
+ Use the pinned environment from `uv sync --locked`, then run the shared gates:
62
+
63
+ ```bash
64
+ uv sync --locked
65
+ uvx pre-commit run --all-files
66
+ uvx pre-commit run --all-files --hook-stage pre-push
67
+ ```
68
+
69
+ For focused feedback, run the smallest affected tests with the locked
70
+ environment, for example:
71
+
72
+ ```bash
73
+ uv run --locked --extra test pytest -q tests/test_langfuse_development_skill.py
74
+ uv run --locked --extra test pytest -q tests/test_pages_workflow.py
75
+ ```
76
+
77
+ The canonical `.pre-commit-config.yaml` delegates connector-standard, secrets,
78
+ spec, tests-fast, and dependency-readiness to `Knuckles-Team/pipelines` at
79
+ `rev: main`. Do not copy those hooks locally or bypass a failing check.
80
+
81
+ ## Connector-specific checks
82
+
83
+ - Keep Langfuse API operation names, request models, pagination, and response
84
+ projections stable when changing `langfuse_agent/api/`; add a focused mocked
85
+ request test for a changed provider path.
86
+ - Preserve the validated host, SDK TLS profile, credential-reference, and OIDC
87
+ delegation behavior in `langfuse_agent/auth.py`. Translate provider failures
88
+ through the existing client boundary and keep raw inputs out of persisted
89
+ graph records.
90
+ - Keep observability, dataset, prompt/model, management, and KG tools registered
91
+ through the existing modules under `langfuse_agent/tools/`. Keep source
92
+ metadata tenant-neutral and ingestion best-effort only where the current
93
+ implementation already defines that behavior.
94
+ - Keep `langfuse_agent/skills/`, `langfuse_agent/ontology/`,
95
+ `langfuse_agent/connectors/`, prompts, and `langfuse_agent/mcp_config.json`
96
+ in package data. Documentation is published by the existing Pages workflow
97
+ with its checked-in spec dashboard configuration and
98
+ `pages_pipeline.yml@main` caller.
99
+
100
+ ## Packaging and publication
101
+
102
+ `pyproject.toml` packages `skills/**`, `ontology/**`, `connectors/**`, prompts,
103
+ and `mcp_config.json` and exposes the `langfuse-mcp` project script. When
104
+ packaged content changes, inspect the build output for
105
+ `langfuse_agent/skills/langfuse-agent-development/SKILL.md`; leave the current
106
+ package version and lock entry unchanged unless an existing release contract
107
+ requires a release. Do not commit generated Docker artifacts or claim package,
108
+ container, or Pages publication from a local build; require exact hosted
109
+ evidence for those claims.
110
+
111
+ ## Delivery discipline
112
+
113
+ Work in a real Git worktree based on `origin/main`. Inspect the complete diff,
114
+ stage only reviewed paths, and verify `git status --short` after every gate. Do
115
+ not use `git stash`, `git add -A`, or `git add .`; preserve unrelated working
116
+ tree changes. Keep runtime, ontology, status, and generated artifacts outside a
117
+ bounded documentation or skill slice unless the owning requirement explicitly
118
+ requires them.
@@ -1,8 +1,8 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: langfuse-agent
3
- Version: 2.3.4
3
+ Version: 2.3.6
4
4
  Summary: Agent for interacting with Langfuse Observability API
5
- Author: Project Contributors
5
+ Author: Repository Maintainers
6
6
  License-Expression: MIT
7
7
  Classifier: Development Status :: 4 - Beta
8
8
  Classifier: Environment :: Console
@@ -11,13 +11,9 @@ Classifier: Programming Language :: Python :: 3
11
11
  Requires-Python: >=3.12
12
12
  Description-Content-Type: text/markdown
13
13
  License-File: LICENSE
14
- Requires-Dist: agent-connector-sdk[mcp]<1.0.0,>=0.4.1
14
+ Requires-Dist: agent-connector-sdk[mcp]<0.6.0,>=0.5.4
15
15
  Requires-Dist: langfuse<5,>=4
16
16
  Requires-Dist: requests>=2.34.2
17
- Provides-Extra: mcp
18
- Requires-Dist: agent-connector-sdk[mcp]<1.0.0,>=0.4.1; extra == "mcp"
19
- Provides-Extra: all
20
- Requires-Dist: agent-connector-sdk[mcp]<1.0.0,>=0.4.1; extra == "all"
21
17
  Provides-Extra: test
22
18
  Requires-Dist: pytest-xdist>=3.8.0; extra == "test"
23
19
  Requires-Dist: pytest>=9.1.1; extra == "test"
@@ -50,8 +46,6 @@ Dynamic: license-file
50
46
  ![PyPI - Wheel](https://img.shields.io/pypi/wheel/langfuse-agent)
51
47
  ![PyPI - Implementation](https://img.shields.io/pypi/implementation/langfuse-agent)
52
48
 
53
- *Version: 2.3.4*
54
-
55
49
  > **Documentation** — Installation, deployment, usage across the API, CLI, and MCP
56
50
  > interfaces, and guidance for provisioning the Langfuse platform are maintained in
57
51
  > the [official documentation](https://knuckles-team.github.io/langfuse-agent/).
@@ -30,7 +30,6 @@ langfuse_agent/api/api_client_datasets.py
30
30
  langfuse_agent/api/api_client_management.py
31
31
  langfuse_agent/api/api_client_observability.py
32
32
  langfuse_agent/api/api_client_prompts_models.py
33
- langfuse_agent/connectors/__init__.py
34
33
  langfuse_agent/mcp/__init__.py
35
34
  langfuse_agent/ontology/__init__.py
36
35
  langfuse_agent/ontology/certification.json
@@ -39,9 +38,8 @@ langfuse_agent/ontology/fixtures/records.json
39
38
  langfuse_agent/ontology/mappings/source.yaml
40
39
  langfuse_agent/ontology/migrations/manifest.json
41
40
  langfuse_agent/ontology/shapes/connector.shacl.ttl
42
- langfuse_agent/prompts/__init__.py
43
41
  langfuse_agent/prompts/observability_specialist.json
44
- langfuse_agent/skills/__init__.py
42
+ langfuse_agent/skills/langfuse-agent-development/SKILL.md
45
43
  langfuse_agent/skills/langfuse-agent-operations/SKILL.md
46
44
  langfuse_agent/skills/langfuse-agent-operations/agents/openai.yaml
47
45
  langfuse_agent/skills/langfuse-agent-operations/references/catalog.md
@@ -59,7 +57,6 @@ langfuse_agent/tools/observability.py
59
57
  langfuse_agent/tools/prompts.py
60
58
  tests/test_api_parity_gate.py
61
59
  tests/test_auth.py
62
- tests/test_default_content_surfaces.py
63
60
  tests/test_documentation_privacy.py
64
61
  tests/test_fleet_name.py
65
62
  tests/test_init.py
@@ -67,9 +64,10 @@ tests/test_init_dynamics.py
67
64
  tests/test_kg_ingest.py
68
65
  tests/test_kg_tool.py
69
66
  tests/test_langfuse_api.py
67
+ tests/test_langfuse_development_skill.py
70
68
  tests/test_langfuse_models.py
71
69
  tests/test_mcp_brute_force.py
72
- tests/test_mcp_server.py
70
+ tests/test_pages_workflow.py
73
71
  tests/test_placeholder.py
74
72
  tests/test_release_version.py
75
73
  tests/test_tools_dispatch_characterization.py
@@ -0,0 +1,8 @@
1
+ [agent_connector_sdk.connector]
2
+ langfuse-mcp = langfuse_agent:connector
3
+
4
+ [agent_connector_sdk.prompt_providers]
5
+ langfuse-agent = langfuse_agent.prompts
6
+
7
+ [console_scripts]
8
+ langfuse-mcp = agent_connector_sdk.cli:serve
@@ -1,17 +1,11 @@
1
- agent-connector-sdk[mcp]<1.0.0,>=0.4.1
1
+ agent-connector-sdk[mcp]<0.6.0,>=0.5.4
2
2
  langfuse<5,>=4
3
3
  requests>=2.34.2
4
4
 
5
- [all]
6
- agent-connector-sdk[mcp]<1.0.0,>=0.4.1
7
-
8
5
  [docs]
9
6
  mkdocs>=1.6.1
10
7
  mkdocs-material>=9.7.7
11
8
 
12
- [mcp]
13
- agent-connector-sdk[mcp]<1.0.0,>=0.4.1
14
-
15
9
  [test]
16
10
  pytest-xdist>=3.8.0
17
11
  pytest>=9.1.1
@@ -5,19 +5,17 @@ backend-path = ["."]
5
5
 
6
6
  [project]
7
7
  name = "langfuse-agent"
8
- version = "2.3.4"
8
+ version = "2.3.6"
9
9
  description = "Agent for interacting with Langfuse Observability API"
10
10
  readme = "README.md"
11
11
  classifiers = [ "Development Status :: 4 - Beta", "Environment :: Console", "Operating System :: POSIX :: Linux", "Programming Language :: Python :: 3",]
12
12
  requires-python = ">=3.12"
13
- dependencies = [ "agent-connector-sdk[mcp]>=0.4.1,<1.0.0", "langfuse>=4,<5", "requests>=2.34.2",]
13
+ dependencies = [ "agent-connector-sdk[mcp]>=0.5.4,<0.6.0", "langfuse>=4,<5", "requests>=2.34.2",]
14
14
  license = "MIT"
15
15
  [[project.authors]]
16
- name = "Project Contributors"
16
+ name = "Repository Maintainers"
17
17
 
18
18
  [project.optional-dependencies]
19
- mcp = [ "agent-connector-sdk[mcp]>=0.4.1,<1.0.0",]
20
- all = [ "agent-connector-sdk[mcp]>=0.4.1,<1.0.0",]
21
19
  test = [
22
20
  "pytest-xdist>=3.8.0", "pytest>=9.1.1", "pytest-asyncio>=1.4.0", "pytest-cov>=7.1.0",]
23
21
  docs = [
@@ -26,20 +24,14 @@ docs = [
26
24
  ]
27
25
 
28
26
  [project.scripts]
29
- langfuse-mcp = "langfuse_agent.mcp_server:mcp_server"
30
-
31
- [project.entry-points."agent_connector_sdk.skill_providers"]
32
- langfuse-agent = "langfuse_agent.skills"
33
-
34
- [project.entry-points."agent_connector_sdk.ontology_providers"]
35
- langfuse-agent = "langfuse_agent.ontology"
27
+ langfuse-mcp = "agent_connector_sdk.cli:serve"
36
28
 
37
29
  [project.entry-points."agent_connector_sdk.prompt_providers"]
38
30
  langfuse-agent = "langfuse_agent.prompts"
39
31
 
40
32
  # The one declared connector identity: the fleet name (SDK-CONNECTOR-CONTROL-R071).
41
33
  [project.entry-points."agent_connector_sdk.connector"]
42
- langfuse-mcp = "langfuse_agent"
34
+ langfuse-mcp = "langfuse_agent:connector"
43
35
 
44
36
  [tool.uv.workspace]
45
37
  members = ["."]
@@ -48,6 +40,7 @@ members = ["."]
48
40
  include-package-data = true
49
41
 
50
42
  [tool.ruff]
43
+ extend-exclude = ["tests", "scripts"]
51
44
  line-length = 88
52
45
  target-version = "py312"
53
46
 
@@ -86,3 +79,13 @@ override-dependencies = [
86
79
 
87
80
  [tool.pipelines_hooks.ste]
88
81
  exempt = ["specs/*", "specs/**/*"]
82
+
83
+ [tool.pipelines.container]
84
+ port = 8004
85
+ debug_apt = ["default-jre", "ripgrep", "tree", "fd-find", "curl", "nano", "build-essential", "cmake", "libssl-dev", "libcurl4-openssl-dev", "pkg-config", "cargo", "rustc"]
86
+ limits = {"mcp" = {"memory_limit_env" = "AGENT_CONTAINER_MEMORY_LIMIT", "memory_limit" = "4g", "cpu_limit_env" = "AGENT_CONTAINER_CPU_LIMIT", "cpu_limit" = "2.0"}}
87
+ compose_env = ["LANGFUSE_HOST", "LANGFUSE_PUBLIC_KEY", "LANGFUSE_SECRET_KEY", "REQUESTS_CA_BUNDLE", "SSL_CERT_FILE"]
88
+
89
+ [tool.pipelines.security]
90
+ license_allowed = ["CDLA-Permissive-2.0", "LGPL-3.0-only", "LGPL-3.0-or-later", "MIT-CMU", "PSF-2.0", "W3C-20150513", "zlib-acknowledgement"]
91
+ license_denied = ["AGPL-1.0-only", "AGPL-1.0-or-later", "GPL-1.0-only", "GPL-1.0-or-later", "GPL-2.0-only", "GPL-2.0-or-later"]
@@ -0,0 +1,49 @@
1
+ """Fail-closed coverage for the Langfuse API-to-MCP surface, measured on the served tools.
2
+
3
+ The connector surface comes from the SDK declaration (``Connector(api=LangfuseApi, ...)``); these tests build the server
4
+ the way the console script does and compare its tools with the public methods of the API client.
5
+ """
6
+
7
+ from __future__ import annotations
8
+
9
+ import asyncio
10
+ import inspect
11
+
12
+ import pytest
13
+ from agent_connector_sdk.connector import build_server
14
+ from fastmcp import Client
15
+
16
+ from langfuse_agent.api_client import LangfuseApi
17
+
18
+
19
+ def _served_tool_names() -> list[str]:
20
+ _, mcp = build_server("langfuse_agent", command_args=["--transport", "stdio"])
21
+
22
+ async def _list() -> list[str]:
23
+ async with Client(mcp) as client:
24
+ return [tool.name for tool in await client.list_tools()]
25
+
26
+ return asyncio.run(_list())
27
+
28
+
29
+ def test_current_composed_client_is_fully_bound_to_mcp() -> None:
30
+ names = _served_tool_names()
31
+ methods = [n for n, _f in inspect.getmembers(LangfuseApi, inspect.isfunction) if not n.startswith("_")]
32
+
33
+ assert methods
34
+ unbound = [m for m in methods if not any(name.endswith(m) for name in names)]
35
+ assert not unbound, f"API methods with no served tool: {unbound}"
36
+
37
+
38
+ def test_the_served_surface_is_built_instead_of_skipped() -> None:
39
+ names = _served_tool_names()
40
+
41
+ assert len(names) > 0
42
+ assert all(name.startswith("langfuse_") for name in names)
43
+
44
+
45
+ def test_building_a_server_fails_closed_without_a_surface() -> None:
46
+ with pytest.raises(Exception) as raised: # noqa: PT011 - any failure to build counts, none may serve an empty surface
47
+ build_server("no_such_connector_package", command_args=["--transport", "stdio"])
48
+
49
+ assert raised.value is not None