> ## Documentation Index
> Fetch the complete documentation index at: https://futureagi.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Quickstart

### 1. Configure Your Environment

Set up your environment variables to connect to Future AGI. Get your API keys [here](https://app.futureagi.com/dashboard/keys)

<CodeGroup>
  ```python Python theme={null}
  import os
  os.environ["FI_API_KEY"] = "YOUR_API_KEY"
  os.environ["FI_SECRET_KEY"] = "YOUR_SECRET_KEY"
  ```

  ```typescript JS/TS theme={null}
  process.env.FI_API_KEY = FI_API_KEY;
  process.env.FI_SECRET_KEY = FI_SECRET_KEY;
  ```
</CodeGroup>

### 2. Register Your Observe Project

Register your project with the necessary configuration.

<CodeGroup>
  ```python Python theme={null}
  from fi_instrumentation import register, Transport
  from fi_instrumentation.fi_types import ProjectType

  # Setup OTel via our register function
  trace_provider = register(
      project_type=ProjectType.OBSERVE,  
      project_name="FUTURE_AGI",            # Your project name
      transport=Transport.GRPC,             # Transport mechanism for your traces
  )
  ```

  ```typescript JS/TS theme={null}
  import { register, ProjectType } from "@traceai/fi-core";

  const traceProvider = register({
      project_type: ProjectType.OBSERVE,
      project_name: "FUTURE_AGI"
  });
  ```
</CodeGroup>

### Configuration Parameters:

* **project\_type**: Set as `ProjectType.OBSERVE` for observe
* **project\_name**: A descriptive name for your project
* **transport** (optional): Set the transport for your traces. The available options are `GRPC` and `HTTP`.

## Instrument your project:

There are 2 ways to implement tracing in your project

1. Auto Instrumentor : Instrument your project with FutureAGI's [Auto Instrumentor](/future-agi/products/observability/auto-instrumentation/overview). Recommended for most use cases.
2. Manual Tracing : Manually track your project with [Open Telemetry](/future-agi/products/observability/concept/otel). Useful for more customized tracing. [Learn more →](/future-agi/get-started/observability/manual-tracing/set-up-tracing)

### Example: Instrumenting with Auto Instrumentor ( OpenAI )

First, install the traceAI openai package:

<CodeGroup>
  ```bash Python theme={null}
  pip install traceAI-openai
  ```

  ```bash JS/TS theme={null}
  npm install @traceai/openai
  ```
</CodeGroup>

Instrument your project with FutureAGI's OpenAI Instrumentor.

<CodeGroup>
  ```python Python theme={null}
  from traceai_openai import OpenAIInstrumentor

  OpenAIInstrumentor().instrument(tracer_provider=trace_provider)
  ```

  ```typescript JS/TS theme={null}
  import { OpenAIInstrumentation } from "@traceai/openai";

  const openaiInstrumentation = new OpenAIInstrumentation({});
  ```
</CodeGroup>

Initialize the OpenAI client and make OpenAI requests as you normally would. Our Instrumentor will automatically trace these requests for you, which can be viewed in your [Observe dashboard](https://app.futureagi.com/dashboard/projects/observe).

<CodeGroup>
  ```python Python theme={null}
  from openai import OpenAI

  os.environ["OPENAI_API_KEY"] = "your-openai-api-key"

  client = OpenAI()

  completion = client.chat.completions.create(
      model="gpt-4o",
      messages=[
          {
              "role": "user",
              "content": "Write a one-sentence bedtime story about a unicorn."
          }
      ]
  )

  print(completion.choices[0].message.content)
  ```

  ```typescript JS/TS theme={null}
  import { OpenAI } from "openai";

  const client = new OpenAI({
      apiKey: process.env.OPENAI_API_KEY,
  });

  const completion = await client.chat.completions.create({
      model: "gpt-4o",
      messages: [{ role: "user", content: "Write a one-sentence bedtime story about a unicorn." }],
  });

  console.log(completion.choices[0].message.content);
  ```
</CodeGroup>

To know more about the supported frameworks and how to instrument them, check out our [Auto Instrumentation](/future-agi/products/observability/auto-instrumentation/overview) page.
