Skip to main content

Univer Use: LangGraph-powered agent utilities and tools for Univer spreadsheets

Project description

Univer Use

LangGraph-powered agent utilities and tools for Univer spreadsheets. This library provides a ready-to-use graph entrypoint and helper tools to build agents that operate against Univer via Univer-MCP.

Features

  • LangGraph graph entrypoint: univer_use/graph.py:build_graph
  • Spreadsheet action agent with MCP tools
  • Prompt templates packaged with the library

Install

  • pip: pip install univer-use
  • uv: uv add univer-use
  • Poetry: poetry add univer-use

Requirements

  • Python 3.11+
  • Credentials via environment or .env (python-dotenv):
    • OPENROUTER_API_KEY – API key for your OpenRouter-compatible provider
    • OPENROUTER_ENDPOINT – Base URL for the provider endpoint
    • UNIVER_API_KEY – Univer API key (if required by your MCP setup)

Quickstart Minimal example to compile and run the graph once:

import asyncio
from univer_use import build_graph

async def main():
    graph = await build_graph()
    # Provide initial state. At minimum, include a conversation_id.
    state = {
        "messages": [],
        "conversation_id": "local-dev",
    }
    result = await graph.ainvoke(state)
    print(result)

asyncio.run(main())

Run Locally with LangGraph CLI The repo includes a local dev config that uses the build_graph entrypoint:

langgraph dev --config examples/sheet_edit/langgraph.json --debug-port 5678 --allow-blocking

This uses the graph at univer_use/graph.py:build_graph. Set env vars in .env or your shell before running. See examples/sheet_edit/.env for an example.

Development

  • Install dependencies: uv sync
  • Run tests: uv run pytest -q

License MIT. See LICENSE.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

univer_use-0.1.1a3.tar.gz (138.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

univer_use-0.1.1a3-py3-none-any.whl (20.1 kB view details)

Uploaded Python 3

File details

Details for the file univer_use-0.1.1a3.tar.gz.

File metadata

  • Download URL: univer_use-0.1.1a3.tar.gz
  • Upload date:
  • Size: 138.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for univer_use-0.1.1a3.tar.gz
Algorithm Hash digest
SHA256 15a3ebbc5835a8799855a945cacf64ddc1083c6612e01e2f7e98f4c838771adb
MD5 124db61fe03c832416ea9f11bf33fd3a
BLAKE2b-256 2ad11dce771d0b058a95c23abe8a96afc6ada189fe66a66ecc2c3cab8c3b3680

See more details on using hashes here.

Provenance

The following attestation bundles were made for univer_use-0.1.1a3.tar.gz:

Publisher: release.yml on dream-num/univer-use

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file univer_use-0.1.1a3-py3-none-any.whl.

File metadata

  • Download URL: univer_use-0.1.1a3-py3-none-any.whl
  • Upload date:
  • Size: 20.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for univer_use-0.1.1a3-py3-none-any.whl
Algorithm Hash digest
SHA256 c5b8083e8d2d12c6c841f2c3436af8c7bad49bc09376a02d8b77f25e95cff891
MD5 0ca7c64d0d372aeca2ceade113aeab8b
BLAKE2b-256 61cc88a7c9d59bf78f4178ad3b75ab66b912dde96b7fb123374b9924cc12f57c

See more details on using hashes here.

Provenance

The following attestation bundles were made for univer_use-0.1.1a3-py3-none-any.whl:

Publisher: release.yml on dream-num/univer-use

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page