Skip to content

Commit 79c38c5

Browse files
authored
Clean up v2 docs links (#1058)
fix cross links in v2 docs
1 parent 8fec230 commit 79c38c5

File tree

10 files changed

+8
-111
lines changed

10 files changed

+8
-111
lines changed

docs/v1/concepts/core-concepts.mdx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,6 @@ AgentOps can exist in one of two states:
4747

4848
By default, AgentOps operates in single-session mode. All of the [base SDK functions](/v1/usage/sdk-reference) work as expected.
4949

50-
<Note>Under the hood, when you only have one session at a time, AgentOps can use functions like `agentops.add_tags(...)` and know that you want to perform the function on the one and only active session.</Note>
51-
5250
As soon as you create a second session, AgentOps enters **Multi-Session Mode**. As long as more than one session is active, the [base SDK functions](/v1/usage/sdk-reference) will no longer work.
5351

5452
If multiple sessions exist, you are expected to call the function on the relevant session. Ex

docs/v1/concepts/sessions.mdx

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -41,17 +41,6 @@ Optionally, sessions may include:
4141
**Params**
4242
- **event** ([Event](/v1/concepts/events#event-class)): The Event to record as part of the session
4343

44-
45-
#### `add_tags`
46-
**Params**
47-
- **tags** (List[str]): a list of tags to assign to append to the current tags
48-
49-
#### `set_tags`
50-
**Params**
51-
- **tags** (List[str]): a list of tags to assign to append to set
52-
53-
_Note: Overrides any current tags_
54-
5544
#### `get_analytics`
5645
**Returns** (dict): A dictionary containing various analytics metrics for the session.
5746

@@ -183,7 +172,7 @@ _More info for the curious_
183172

184173
Under the hood, `agentops.init()` creates a `Client` object with various configuration options. Whenever you start a new session, these configuration options will automatically
185174
be applied. You can also apply different configuration options when you start a new session by passing in a
186-
[Configuration](/v1/usage/sdk-reference/#configuration) object.
175+
[Config](/v1/usage/sdk-reference/#config) object.
187176

188177
<script type="module" src="/scripts/github_stars.js"></script>
189178
<script type="module" src="/scripts/adjust_api_dynamically.js"></script>

docs/v1/usage/advanced-configuration.mdx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,6 @@ Find your AgentOps API Key in your Settings > [Projects & API Keys](https://app.
1818
#### Optional settings:
1919

2020
```python .env
21-
# Secondary API Key for simultaneously recording to a second project
22-
AGENTOPS_PARENT_KEY=<YOUR PARENT KEY>
2321
# The AgentOps API endpoint. Defaults to https://api.agentops.ai
2422
AGENTOPS_API_ENDPOINT=https://api.agentops.ai
2523
# Logging level. <DEBUG, INFO, CRITICAL>. Defaults to INFO

docs/v1/usage/langchain-callback-handler.mdx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,7 @@ When calling `.init()`, pass in the proper parameter.
3636
`agentops.init(instrument_llm_calls=False)`
3737

3838
If you are building an Agent framework or other SDK and adding support for AgentOps, you cannot guarantee that your end user will
39-
properly include `instrument_llm_calls=False`. In this case, call
40-
`agentops.stop_instrumenting()`
39+
properly include `instrument_llm_calls=False`.
4140

4241
### Implement Callback Handler
4342

docs/v1/usage/multiple-sessions.mdx

Lines changed: 2 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,6 @@ In most development and scripting use cases, having only one session active at a
99

1010
By default, AgentOps operates in single-session mode. All of the [base SDK functions](/v1/usage/sdk-reference) work as expected.
1111

12-
<Note>Under the hood, when you only have one session at a time, AgentOps can use functions like `agentops.add_tags(...)` and know that you want to perform the function on the one and only active session.</Note>
13-
1412
As soon as you create a second session, AgentOps enters **Multi-Session Mode**. As long as more than one session is active, the [base SDK functions](/v1/usage/sdk-reference) will no longer work.
1513

1614
If multiple sessions exist, you are expected to call the function on the relevant session. Ex:
@@ -63,14 +61,10 @@ Functions on `agentops` will no longer work in multi-session mode
6361
<CodeGroup>
6462
```python works ✅
6563
session.end_session(...)
66-
session.add_tags(...)
67-
session.set_tags(...)
6864
```
6965

7066
```python does not work ❌
7167
agentops.end_session(...)
72-
agentops.add_tags(...)
73-
agentops.set_tags(...)
7468
```
7569
</CodeGroup>
7670

@@ -185,46 +179,16 @@ obs_response = observed_create(
185179
)
186180
```
187181

188-
[//]: # (Alternatively, you can include the session object as a keyword parameter in the completion call.)
189-
190-
[//]: # ()
191-
[//]: # (```python)
192-
193-
[//]: # (import agentops)
194-
195-
[//]: # (import openai)
196-
197-
[//]: # ()
198-
[//]: # (session = agentops.start_session&#40;&#41;)
199-
200-
[//]: # (messages = [{"role": "user", "content": "Hello"}])
201-
202-
[//]: # (response = openai.chat.completions.create&#40;)
203-
204-
[//]: # ( model="gpt-3.5-turbo",)
205-
206-
[//]: # ( messages=messages,)
207-
208-
[//]: # ( temperature=0.5,)
209-
210-
[//]: # ( session=session)
211-
212-
[//]: # (&#41;)
213-
214-
[//]: # (```)
215-
216-
[//]: # ()
217-
[//]: # (<Warning>Passing `session` as a keyword parameter is functional, but will likely show an Unexpected Argument warning.</Warning>)
218182

219183
If you make an LLM completion call without one of these methods while you currently have more than one active session, a `MultiSessionException` will be raised.
220184

221185

222186
# Exceptions
223187

188+
224189
### `MultiSessionException`
225-
_"If multiple sessions exist, you must use session.function(). Example: session.add_tags(...) instead of agentops.add_tags(...)."_
226190

227191
Receiving this exception means that you tried to perform a function on the SDK base, but at runtime had more than one active session.
228192

229193
### `NoSessionException`
230-
A [session](/v1/concepts/session) action was attempted while no session existed on the client.
194+
A [session](/v1/concepts/session) action was attempted while no session existed on the client.

docs/v1/usage/sdk-reference.mdx

Lines changed: 2 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ The first element of AgentOps is always calling .init()
1616
**Parameters**:
1717

1818
- `api_key` (str, optional): API Key for AgentOps services. If not provided, the key will be read from the `AGENTOPS_API_KEY` environment variable.
19-
- `parent_key` (str, optional): Organization key to give visibility of all user sessions within the user's organization. If not provided, the key will be read from the `AGENTOPS_PARENT_KEY` environment variable.
2019
- `endpoint` (str, optional): The endpoint for the AgentOps service. Defaults to 'https://api.agentops.ai'.
2120
- `max_wait_time` (int, optional): The maximum time to wait in milliseconds before flushing the queue. Defaults to 30,000 (30 seconds).
2221
- `max_queue_size` (int, optional): The maximum size of the event queue. Defaults to 100.
@@ -40,7 +39,7 @@ Start a new [Session](/v1/concepts/sessions) for recording events.
4039
**Parameters**:
4140

4241
- `tags` (List[str], optional): Tags for the session.
43-
- `config` ([Configuration](#configuration), optional): Client configuration object.
42+
- `config` ([Config](#config), optional): Client configuration object.
4443
- `inherited_session_id` (str, optional): Session ID to continue from an existing session.
4544

4645
**Returns**:
@@ -71,25 +70,6 @@ Record an event with the AgentOps service.
7170

7271
---
7372

74-
### `add_tags()`
75-
76-
Append to session tags at runtime.
77-
78-
**Parameters**:
79-
80-
- `tags` (List[str]): The list of tags to append.
81-
82-
---
83-
84-
### `set_tags()`
85-
86-
Replace session tags at runtime.
87-
88-
**Parameters**:
89-
90-
- `tags` (List[str]): The list of tags to set.
91-
92-
---
9373

9474
### `get_api_key()`
9575

@@ -101,37 +81,17 @@ Retrieve the API key used by the client.
10181

10282
---
10383

104-
### `set_parent_key()`
105-
106-
Set the parent API key which has visibility over projects it is a parent of.
107-
108-
**Parameters**:
109-
110-
- `parent_key` (str): The API key of the parent organization to set.
111-
112-
---
113-
114-
### `stop_instrumenting()`
115-
116-
Stops instrumenting LLM calls. This is typically used by agent frameworks (i.e., [CrewAI](/v1/integrations/crewai) and
117-
[AG2](/v1/integrations/autogen)) to stop using AgentOps' auto-instrumentation of LLM libraries such as OpenAI. This
118-
allows these frameworks to use their own instrumenting or callback handler.
119-
120-
121-
122-
12384

12485
## Types
12586
---
12687

127-
### `Configuration`
88+
### `Config`
12889

12990
Stores the configuration settings for AgentOps clients.
13091

13192
**Parameters**:
13293

13394
- `api_key` (str, optional): API Key for AgentOps services. If not provided, the key will be read from the `AGENTOPS_API_KEY` environment variable. If no key is found, a `ConfigurationError` is raised.
134-
- `parent_key` (str, optional): Organization key to give visibility of all user sessions within the user's organization. If not provided, the key will be read from the `AGENTOPS_PARENT_KEY` environment variable.
13595
- `endpoint` (str, optional): The endpoint for the AgentOps service. If not provided, the endpoint will be read from the `AGENTOPS_API_ENDPOINT` environment variable. Defaults to 'https://api.agentops.ai'.
13696
- `max_wait_time` (int, optional): The maximum time to wait in milliseconds before flushing the queue. Defaults to 30000.
13797
- `max_queue_size` (int, optional): The maximum size of the event queue. Defaults to 100.
@@ -142,7 +102,6 @@ Stores the configuration settings for AgentOps clients.
142102
- **endpoint** (str): Get or set the endpoint for the AgentOps service.
143103
- **max_wait_time** (int): Get or set the maximum wait time in milliseconds before flushing the queue.
144104
- **max_queue_size** (int): Get or set the maximum size of the event queue.
145-
- **parent_key** (str, optional): Get or set the organization key for session visibility.
146105

147106
---
148107

docs/v1/usage/tracking-llm-calls.mdx

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -28,14 +28,6 @@ To get started, just follow the quick start guide.
2828
</Card>
2929
</CardGroup>
3030

31-
### Stop Tracking LLM Calls
32-
33-
To stop tracking LLM calls after running `agentops.init()`, you can call `agentops.stop_instrumenting()`.
34-
35-
This function reverts the changes made to your LLM provider's module, removing AgentOps instrumentation.
36-
37-
_Special consideration for Cohere: Calling `stop_instrumenting()` has no effect on previously instantiated Cohere clients. You must create a new Cohere client after calling this function._
38-
3931
<script type="module" src="/scripts/github_stars.js"></script>
4032
<script type="module" src="/scripts/scroll-img-fadein-animation.js"></script>
4133
<script type="module" src="/scripts/button_heartbeat_animation.js"></script>

docs/v2/integrations/langchain.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ import EnvTooltip from '/snippets/add-env-tooltip.mdx'
6565
AGENTOPS_API_KEY=<YOUR API KEY>
6666
```
6767
</CodeGroup>
68-
Read more about environment variables in [Advanced Configuration](/v1/usage/advanced-configuration)
68+
Read more about environment variables in [Advanced Configuration](/v2/usage/advanced-configuration)
6969
</Step>
7070
<Step title="Run your agent">
7171
Execute your program and visit [app.agentops.ai/traces](https://app.agentops.ai/traces) to observe your LangChain Agent! 🕵️

docs/v2/introduction.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ mode: "wide"
2020
<Card title="OpenAI Agents SDK" icon={<img src="https://www.github.com/agentops-ai/agentops/blob/main/docs/images/external/openai/openai-logomark.png?raw=true" alt="OpenAI Agents SDK" />} iconType="image" href="/v2/integrations/agentssdk" />
2121
<Card title="CrewAI" icon={<img src="https://www.github.com/agentops-ai/agentops/blob/main/docs/images/external/crew/crew.png?raw=true" alt="CrewAI" />} iconType="image" href="/v2/integrations/crewai" />
2222
<Card title="AG2" icon={<img src="https://www.github.com/agentops-ai/agentops/blob/main/docs/images/external/autogen/ag2.svg?raw=true" alt="Autogen"/>} iconType="image" href="/v2/integrations/ag2" />
23-
<Card title="AutoGen" icon={<img src="https://www.github.com/agentops-ai/agentops/blob/main/docs/images/external/microsoft/microsoft_logo.svg?raw=true" alt="AutoGen" />} iconType="image" href="/v1/integrations/autogen" />
23+
<Card title="AutoGen" icon={<img src="https://www.github.com/agentops-ai/agentops/blob/main/docs/images/external/microsoft/microsoft_logo.svg?raw=true" alt="AutoGen" />} iconType="image" href="/v2/integrations/autogen" />
2424
<Card title="OpenAI" icon={<img src="https://www.github.com/agentops-ai/agentops/blob/main/docs/images/external/openai/openai-logomark.png?raw=true" alt="OpenAI" />} iconType="image" href="/v2/integrations/openai" />
2525
<Card title="Anthropic" icon={<img src="https://www.github.com/agentops-ai/agentops/blob/main/docs/images/external/anthropic/anthropic_icon_slate.png?raw=true" alt="Anthropic" />} iconType="image" href="/v2/integrations/anthropic" />
2626
<Card title="LangChain" icon={<img src="https://www.github.com/agentops-ai/agentops/blob/main/docs/images/external/langchain/langchain-logo.svg?raw=true" alt="LangChain" />} iconType="image" href="/v2/integrations/langchain" />

docs/v2/usage/advanced-configuration.mdx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,6 @@ Find your AgentOps API Key in your Settings > [Projects & API Keys](https://app.
1818
#### Optional settings:
1919

2020
```python .env
21-
# Secondary API Key for simultaneously recording to a second project
22-
AGENTOPS_PARENT_KEY=<YOUR PARENT KEY>
2321
# The AgentOps API endpoint. Defaults to https://api.agentops.ai
2422
AGENTOPS_API_ENDPOINT=https://api.agentops.ai
2523
# Logging level. <DEBUG, INFO, CRITICAL>. Defaults to INFO

0 commit comments

Comments
 (0)