monocle-apptrace


Namemonocle-apptrace JSON
Version 0.4.2 PyPI version JSON
download
home_pageNone
Summarypackage with monocle genAI tracing
upload_time2025-06-26 15:21:25
maintainerNone
docs_urlNone
authorNone
requires_python>=3.8
licenseNone
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Monocle for tracing GenAI app code

**Monocle** helps developers and platform engineers building or managing GenAI apps monitor these in prod by making it easy to instrument their code to capture traces that are compliant with open-source cloud-native observability ecosystem. 

**Monocle** is a community-driven OSS framework for tracing GenAI app code governed as a [Linux Foundation AI & Data project](https://lfaidata.foundation/projects/monocle/). 

## Why Monocle

Monocle is built for: 
- **app developers** to trace their app code in any environment without lots of custom code decoration 
- **platform engineers** to instrument apps in prod through wrapping instead of asking app devs to recode
- **GenAI component providers** to add observability features to their products 
- **enterprises** to consume traces from GenAI apps in their existing open-source observability stack

Benefits:
- Monocle provides an implementation + package, not just a spec 
   - No expertise in OpenTelemetry spec required
   - No bespoke implementation of that spec required
   - No last-mile GenAI domain specific code required to instrument your app
- Monocle provides consistency  
   - Connect traces across app code executions, model inference or data retrievals
   - No cleansing of telemetry data across GenAI component providers required
   - Works the same in personal lab dev or org cloud prod environments
   - Send traces to location that fits your scale, budget and observability stack
- Monocle is fully open source and community driven
   - No vendor lock-in
   - Implementation is transparent
   - You can freely use or customize it to fit your needs 

## What Monocle provides

- Easy to [use](#use-monocle) code instrumentation
- OpenTelemetry compatible format for [spans](src/monocle_apptrace/metamodel/spans/span_format.json). 
- Community-curated and extensible [metamodel](src/monocle_apptrace/metamodel/README.md) for consisent tracing of GenAI components. 
- Export to local and cloud storage 

## Use Monocle

- Get the Monocle package
  
```
    pip install monocle_apptrace 
```
- Instrument your app code
     - Import the Monocle package
       ```
          from monocle_apptrace.instrumentor import setup_monocle_telemetry
       ```
     - Setup instrumentation in your ```main()``` function  
       ``` 
          setup_monocle_telemetry(workflow_name="your-app-name")
       ```         
- (Optionally) Modify config to alter where traces are sent

See [Monocle user guide](Monocle_User_Guide.md) for more details.
  

## Roadmap 

Goal of Monocle is to support tracing for apps written in *any language* with *any LLM orchestration or agentic framework* and built using models, vectors, agents or other components served up by *any cloud or model inference provider*. 

Current version supports: 
- Language: (🟢) Python , (🔜) [Typescript](https://github.com/monocle2ai/monocle-typescript) 
- LLM-frameworks: (🟢) Langchain, (🟢) Llamaindex, (🟢) Haystack, (🔜) Flask
- LLM inference providers: (🟢) OpenAI, (🟢) Azure OpenAI, (🟢) Nvidia Triton, (🔜) AWS Bedrock, (🔜) Google Vertex, (🔜) Azure ML, (🔜) Hugging Face
- Vector stores: (🟢) FAISS, (🔜) OpenSearch, (🔜) Milvus
- Exporter: (🟢) stdout, (🟢) file, (🔜) Azure Blob Storage, (🔜) AWS S3, (🔜) Google Cloud Storage


## Get involved
### Provide feedback
- Submit issues and enhancements requests via Github issues

### Contribute
- Monocle is community based open source project. We welcome your contributions. Please refer to the CONTRIBUTING and CODE_OF_CONDUCT for guidelines. The [contributor's guide](CONTRIBUTING.md) provides technical details of the project.


            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "monocle-apptrace",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": null,
    "author": null,
    "author_email": null,
    "download_url": "https://files.pythonhosted.org/packages/ec/c5/b5b20cd6f6f9b8cc4fac81475e734d349db024ca88d3e124cea6b1f3b9c0/monocle_apptrace-0.4.2.tar.gz",
    "platform": null,
    "description": "# Monocle for tracing GenAI app code\n\n**Monocle** helps developers and platform engineers building or managing GenAI apps monitor these in prod by making it easy to instrument their code to capture traces that are compliant with open-source cloud-native observability ecosystem. \n\n**Monocle** is a community-driven OSS framework for tracing GenAI app code governed as a [Linux Foundation AI & Data project](https://lfaidata.foundation/projects/monocle/). \n\n## Why Monocle\n\nMonocle is built for: \n- **app developers** to trace their app code in any environment without lots of custom code decoration \n- **platform engineers** to instrument apps in prod through wrapping instead of asking app devs to recode\n- **GenAI component providers** to add observability features to their products \n- **enterprises** to consume traces from GenAI apps in their existing open-source observability stack\n\nBenefits:\n- Monocle provides an implementation + package, not just a spec \n   - No expertise in OpenTelemetry spec required\n   - No bespoke implementation of that spec required\n   - No last-mile GenAI domain specific code required to instrument your app\n- Monocle provides consistency  \n   - Connect traces across app code executions, model inference or data retrievals\n   - No cleansing of telemetry data across GenAI component providers required\n   - Works the same in personal lab dev or org cloud prod environments\n   - Send traces to location that fits your scale, budget and observability stack\n- Monocle is fully open source and community driven\n   - No vendor lock-in\n   - Implementation is transparent\n   - You can freely use or customize it to fit your needs \n\n## What Monocle provides\n\n- Easy to [use](#use-monocle) code instrumentation\n- OpenTelemetry compatible format for [spans](src/monocle_apptrace/metamodel/spans/span_format.json). \n- Community-curated and extensible [metamodel](src/monocle_apptrace/metamodel/README.md) for consisent tracing of GenAI components. \n- Export to local and cloud storage \n\n## Use Monocle\n\n- Get the Monocle package\n  \n```\n    pip install monocle_apptrace \n```\n- Instrument your app code\n     - Import the Monocle package\n       ```\n          from monocle_apptrace.instrumentor import setup_monocle_telemetry\n       ```\n     - Setup instrumentation in your ```main()``` function  \n       ``` \n          setup_monocle_telemetry(workflow_name=\"your-app-name\")\n       ```         \n- (Optionally) Modify config to alter where traces are sent\n\nSee [Monocle user guide](Monocle_User_Guide.md) for more details.\n  \n\n## Roadmap \n\nGoal of Monocle is to support tracing for apps written in *any language* with *any LLM orchestration or agentic framework* and built using models, vectors, agents or other components served up by *any cloud or model inference provider*. \n\nCurrent version supports: \n- Language: (\ud83d\udfe2) Python , (\ud83d\udd1c) [Typescript](https://github.com/monocle2ai/monocle-typescript) \n- LLM-frameworks: (\ud83d\udfe2) Langchain, (\ud83d\udfe2) Llamaindex, (\ud83d\udfe2) Haystack, (\ud83d\udd1c) Flask\n- LLM inference providers: (\ud83d\udfe2) OpenAI, (\ud83d\udfe2) Azure OpenAI, (\ud83d\udfe2) Nvidia Triton, (\ud83d\udd1c) AWS Bedrock, (\ud83d\udd1c) Google Vertex, (\ud83d\udd1c) Azure ML, (\ud83d\udd1c) Hugging Face\n- Vector stores: (\ud83d\udfe2) FAISS, (\ud83d\udd1c) OpenSearch, (\ud83d\udd1c) Milvus\n- Exporter: (\ud83d\udfe2) stdout, (\ud83d\udfe2) file, (\ud83d\udd1c) Azure Blob Storage, (\ud83d\udd1c) AWS S3, (\ud83d\udd1c) Google Cloud Storage\n\n\n## Get involved\n### Provide feedback\n- Submit issues and enhancements requests via Github issues\n\n### Contribute\n- Monocle is community based open source project. We welcome your contributions. Please refer to the CONTRIBUTING and CODE_OF_CONDUCT for guidelines. The [contributor's guide](CONTRIBUTING.md) provides technical details of the project.\n\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "package with monocle genAI tracing",
    "version": "0.4.2",
    "project_urls": {
        "Homepage": "https://github.com/monocle2ai/monocle",
        "Issues": "https://github.com/monocle2ai/monocle/issues"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "348a5614f683f8a061e884817da4d3d80b9db7016e7fea7d8b4303a6f2b7b44e",
                "md5": "5f180cc2047cae1b35dbd0f81635093a",
                "sha256": "98c45c23ce70fda6f6474f7ea733d34150ed4e3a90e8d9213bdf69fcdc07f105"
            },
            "downloads": -1,
            "filename": "monocle_apptrace-0.4.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "5f180cc2047cae1b35dbd0f81635093a",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 103972,
            "upload_time": "2025-06-26T15:21:24",
            "upload_time_iso_8601": "2025-06-26T15:21:24.265385Z",
            "url": "https://files.pythonhosted.org/packages/34/8a/5614f683f8a061e884817da4d3d80b9db7016e7fea7d8b4303a6f2b7b44e/monocle_apptrace-0.4.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "ecc5b5b20cd6f6f9b8cc4fac81475e734d349db024ca88d3e124cea6b1f3b9c0",
                "md5": "0f68899c670e4a4a95d1a79898aca78e",
                "sha256": "42016f7f0397c47a48a0a4a75442b681089021e99681eb36c3b4099a0cd278ed"
            },
            "downloads": -1,
            "filename": "monocle_apptrace-0.4.2.tar.gz",
            "has_sig": false,
            "md5_digest": "0f68899c670e4a4a95d1a79898aca78e",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 63762,
            "upload_time": "2025-06-26T15:21:25",
            "upload_time_iso_8601": "2025-06-26T15:21:25.500530Z",
            "url": "https://files.pythonhosted.org/packages/ec/c5/b5b20cd6f6f9b8cc4fac81475e734d349db024ca88d3e124cea6b1f3b9c0/monocle_apptrace-0.4.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-06-26 15:21:25",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "monocle2ai",
    "github_project": "monocle",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "tox": true,
    "lcname": "monocle-apptrace"
}
        
Elapsed time: 1.29424s