agentos-python 0.1.0__py3-none-any.whl

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.
@@ -0,0 +1,155 @@
1
+ Metadata-Version: 2.4
2
+ Name: agentos-python
3
+ Version: 0.1.0
4
+ Summary: Python SDK for Agent OS — AI agent observability platform
5
+ Project-URL: Homepage, https://agentos.dev
6
+ Project-URL: Documentation, https://docs.agentos.dev
7
+ Project-URL: Repository, https://github.com/Amitabh1998/agentos-python
8
+ Author-email: Agent OS <hello@agentos.dev>
9
+ License-Expression: MIT
10
+ License-File: LICENSE
11
+ Keywords: agents,ai,llm,observability,tracing
12
+ Classifier: Development Status :: 3 - Alpha
13
+ Classifier: Intended Audience :: Developers
14
+ Classifier: License :: OSI Approved :: MIT License
15
+ Classifier: Programming Language :: Python :: 3
16
+ Classifier: Programming Language :: Python :: 3.10
17
+ Classifier: Programming Language :: Python :: 3.11
18
+ Classifier: Programming Language :: Python :: 3.12
19
+ Classifier: Topic :: Software Development :: Libraries
20
+ Classifier: Typing :: Typed
21
+ Requires-Python: >=3.10
22
+ Requires-Dist: httpx<1,>=0.24
23
+ Provides-Extra: all
24
+ Requires-Dist: anthropic>=0.20; extra == 'all'
25
+ Requires-Dist: langchain-core>=0.2; extra == 'all'
26
+ Requires-Dist: litellm>=1.0; extra == 'all'
27
+ Requires-Dist: openai>=1.0; extra == 'all'
28
+ Requires-Dist: opentelemetry-exporter-otlp-proto-http>=1.20; extra == 'all'
29
+ Requires-Dist: opentelemetry-sdk>=1.20; extra == 'all'
30
+ Provides-Extra: anthropic
31
+ Requires-Dist: anthropic>=0.20; extra == 'anthropic'
32
+ Provides-Extra: crewai
33
+ Requires-Dist: crewai>=0.50; (python_version >= '3.10') and extra == 'crewai'
34
+ Provides-Extra: dev
35
+ Requires-Dist: mypy>=1.11; extra == 'dev'
36
+ Requires-Dist: pytest-asyncio>=0.23; extra == 'dev'
37
+ Requires-Dist: pytest>=8; extra == 'dev'
38
+ Requires-Dist: respx>=0.21; extra == 'dev'
39
+ Requires-Dist: ruff>=0.6; extra == 'dev'
40
+ Provides-Extra: langchain
41
+ Requires-Dist: langchain-core>=0.2; extra == 'langchain'
42
+ Provides-Extra: litellm
43
+ Requires-Dist: litellm>=1.0; extra == 'litellm'
44
+ Provides-Extra: llamaindex
45
+ Requires-Dist: llama-index-core>=0.10; (python_version >= '3.10') and extra == 'llamaindex'
46
+ Provides-Extra: openai
47
+ Requires-Dist: openai>=1.0; extra == 'openai'
48
+ Provides-Extra: otel
49
+ Requires-Dist: opentelemetry-exporter-otlp-proto-http>=1.20; extra == 'otel'
50
+ Requires-Dist: opentelemetry-sdk>=1.20; extra == 'otel'
51
+ Provides-Extra: pydantic-ai
52
+ Requires-Dist: pydantic-ai>=0.1; (python_version >= '3.10') and extra == 'pydantic-ai'
53
+ Description-Content-Type: text/markdown
54
+
55
+ # Agent OS Python SDK
56
+
57
+ Python SDK for [Agent OS](https://agentos.dev) — AI agent observability, experimentation, and security. "PostHog for AI Agents."
58
+
59
+ ## Install
60
+
61
+ ```bash
62
+ pip install agentos
63
+ ```
64
+
65
+ ## Quick Start
66
+
67
+ ```python
68
+ from agentos import wrap_openai
69
+ import openai
70
+
71
+ client = openai.OpenAI()
72
+ client = wrap_openai(client, api_key="aos_...", agent_id="my-agent")
73
+
74
+ # Every LLM call is now automatically traced
75
+ response = client.chat.completions.create(
76
+ model="gpt-4o",
77
+ messages=[{"role": "user", "content": "Hello!"}],
78
+ )
79
+ ```
80
+
81
+ That's it. Open your [Agent OS dashboard](https://app.agentos.dev) to see traces, token usage, costs, and latency.
82
+
83
+ ## Other Ways to Instrument
84
+
85
+ ### `@observe` decorator (Langfuse-compatible)
86
+
87
+ ```python
88
+ from agentos import observe
89
+
90
+ @observe()
91
+ def my_agent(query: str) -> str:
92
+ result = search(query) # auto-traced as child span
93
+ return summarize(result) # auto-traced as child span
94
+
95
+ @observe(as_type="generation")
96
+ def summarize(text: str) -> str:
97
+ return openai_client.chat.completions.create(...)
98
+ ```
99
+
100
+ ### Manual event capture
101
+
102
+ ```python
103
+ from agentos import AgentOS
104
+
105
+ client = AgentOS(api_key="aos_...")
106
+
107
+ client.llm_call("my-agent", model="gpt-4o", system="openai", input_tokens=100, output_tokens=50)
108
+ client.tool_call("my-agent", tool_name="web-search", status="success", duration_ms=120)
109
+ client.eval("my-agent", eval_name="accuracy", score=0.95)
110
+ client.business_event("my-agent", event_name="task_completed")
111
+
112
+ client.flush()
113
+ ```
114
+
115
+ ### Environment variable (zero-code)
116
+
117
+ ```bash
118
+ export AGENTOS_API_KEY=aos_...
119
+ export AGENTOS_ENABLED=true
120
+ python my_agent.py
121
+ ```
122
+
123
+ ## Framework Integrations
124
+
125
+ | Framework | Integration | One-liner |
126
+ |-----------|------------|-----------|
127
+ | **OpenAI** | `wrap_openai(client)` | `from agentos import wrap_openai` |
128
+ | **Anthropic** | `wrap_anthropic(client)` | `from agentos import wrap_anthropic` |
129
+ | **LangChain** | `AgentOSCallbackHandler` | `from agentos.integrations.langchain import AgentOSCallbackHandler` |
130
+ | **LlamaIndex** | `AgentOSCallbackHandler` | `from agentos.integrations.llamaindex import AgentOSCallbackHandler` |
131
+ | **CrewAI** | `@trace_crew` / `instrument_crewai()` | `from agentos.integrations.crewai import trace_crew` |
132
+ | **Pydantic AI** | `wrap_agent()` / `instrument_pydantic_ai()` | `from agentos.integrations.pydantic_ai import wrap_agent` |
133
+ | **LiteLLM** | `patch_litellm()` | `from agentos.integrations.litellm import patch_litellm` |
134
+ | **OpenTelemetry** | OTLP SpanExporter | `from agentos.compat.otel import register` |
135
+
136
+ ## Migrating From Another Platform?
137
+
138
+ Change one import and keep your existing code:
139
+
140
+ | Platform | Migration |
141
+ |----------|-----------|
142
+ | **Langfuse** | `from agentos.compat.langfuse import Langfuse` |
143
+ | **LangSmith** | `from agentos.compat.langsmith import traceable` |
144
+ | **Arize Phoenix** | `from agentos.compat.otel import register` (swap endpoint) |
145
+ | **Helicone** | `from agentos.compat.helicone import get_proxy_config` |
146
+ | **Braintrust** | `from agentos.compat.braintrust import traced, Eval` |
147
+ | **W&B Weave** | `from agentos.compat.weave import op` |
148
+
149
+ ## Documentation
150
+
151
+ Full docs, guides, and API reference: **[docs.agentos.dev](https://docs.agentos.dev)**
152
+
153
+ ## License
154
+
155
+ MIT
@@ -0,0 +1,28 @@
1
+ agentos/__init__.py,sha256=RW2nsVMg0prmr05WI1b2mmEjTQIZ8rZAzxAAPVYm3Og,1265
2
+ agentos/client.py,sha256=wxV9shwOEWetRFkiD9NqwLOw6-C-lyGWuyOllhnAWhY,10024
3
+ agentos/config.py,sha256=Ywx48ME3G7DeRnuiYU9ntgj8H9sJwSLMkW5DAClpPY0,1135
4
+ agentos/decorators.py,sha256=lwrj2bIhwr6LmZQQfnFMEnx57_1T6Dt32LUkorC6e3k,13396
5
+ agentos/events.py,sha256=iv3rWu8LNzxkVAzMFABYjFkh63_XagdmQ2uMvJiR3z4,13383
6
+ agentos/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
7
+ agentos/tracing.py,sha256=VbpuRd8NKhjtXXXI5mj4NB0_eGPiOzJ_LDZ9VM_WMxQ,4963
8
+ agentos/transport.py,sha256=hIILzmmw-7iDH3wVN9G1X8gwILKu22ywUVN0rVPj4K0,10145
9
+ agentos/types.py,sha256=HMYF-YcRp2gjZcwysfEVIKwM-dp37Lr2UFeYuauQIQU,2919
10
+ agentos/compat/__init__.py,sha256=kDKN988OQ_Mg5XsV2AN7kIG2WWSqUBy5U7g8eEjmIxQ,138
11
+ agentos/compat/braintrust.py,sha256=rE6ozdTYPHbzikVLKmdpgYhdg6uvXVGYpabUsZvTShA,2471
12
+ agentos/compat/helicone.py,sha256=Cu0rygmsdhVWLV62G8wjp6JMtqQDBFQAgZFWsIRL2BQ,2058
13
+ agentos/compat/langfuse.py,sha256=UXw9N_jyDkuiaoX7VvFuaLuWv_NKL92p0TXDNQ4QAcw,9540
14
+ agentos/compat/langsmith.py,sha256=E_QifykNTw71b0W2AMVzRqHyFCRweCixZCRriOsOzvY,2179
15
+ agentos/compat/otel.py,sha256=_66SjereFTxbkZmj3cGpwG--vGWOfAMV-Own6tORaRw,5574
16
+ agentos/compat/weave.py,sha256=8KuMuqSbd3PPq2qIfVbtitz_qNp1DaWcRap5tYllMN0,2446
17
+ agentos/integrations/__init__.py,sha256=3lVe8i1_Xh9Il1TrCC7wEAG9kOdAxgH5FfW-JWVM0X0,385
18
+ agentos/integrations/anthropic.py,sha256=cC9RTK0XnPoChZniphwaZ2N-x6aexGuiLp6DPwcuDQU,4398
19
+ agentos/integrations/crewai.py,sha256=ieJIL3KKUf2yDED4qlMmwffESFzAw9ODYYmIM1JXwF0,7065
20
+ agentos/integrations/langchain.py,sha256=9DjelfTd3-wSdGSbx8ll2OZmXMqOO8QoKt0cvPEaTDk,9456
21
+ agentos/integrations/litellm.py,sha256=8alTpIlGwSYLSjh__nGrCWyHowrXS3vpY5Wf33ZzUVA,3739
22
+ agentos/integrations/llamaindex.py,sha256=Ub64ck4K1lzrf82szYDu-WWOZ7Ozy7MK1b3QJg6DFaM,5383
23
+ agentos/integrations/openai.py,sha256=AtpPyL25MZHM9YvfqXalzvy5r3RQ9MopgeTHhHuWVIE,4790
24
+ agentos/integrations/pydantic_ai.py,sha256=pyoX5K6Iu4ClTyhj4_YmL98v6OLCIgcnfgvHKToDn0Y,8481
25
+ agentos_python-0.1.0.dist-info/METADATA,sha256=xsVIrTJNW1hxRSIZJ4R_HmYsG8NxVs-wJy6zI3Y1UHc,5529
26
+ agentos_python-0.1.0.dist-info/WHEEL,sha256=QccIxa26bgl1E6uMy58deGWi-0aeIkkangHcxk2kWfw,87
27
+ agentos_python-0.1.0.dist-info/licenses/LICENSE,sha256=EMzpRWB1_J5sd22e5LXT73zow5TUbyjkCXASAc69B64,1065
28
+ agentos_python-0.1.0.dist-info/RECORD,,
@@ -0,0 +1,4 @@
1
+ Wheel-Version: 1.0
2
+ Generator: hatchling 1.29.0
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Agent OS
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.