Apertis AI Documentation

website·Indexed 32 days ago

https://docs.stima.tech

Developer documentation for the Apertis API and SDKs, featuring text generation, multimodal vision, audio (speech-to-text/TTS), and video generation using models like Veo2, Veo3, and Sora-2. Includes guides for Python, TypeScript, LangChain, and LiteLLM SDKs, as well as integration with tools like Cursor, Cline, and Kilo Code via MCP.

Tokens
71.6K
Snippets
364
Records
549
Agent score
57%

What's inside Apertis

  1. Overview of Crush AI coding agent

    Crush is a terminal-based AI coding agent featuring both a Command Line Interface (CLI) and a Terminal User Interface (TUI). It supports multiple models for code generation, debugging, file operations (creating and modifying files), and technical Q&A.
  2. Overview of Stima Chat capabilities

    Stima Chat is a conversation system developed by Apertis AI that supports interactions with over 100 large language models. Key capabilities include:

    • Bidirectional Multi-Turn Dialogue: The system can both answer questions and proactively ask them.
    • Multilingual Support: Supports Chinese, English, Japanese, Korean, and other languages.
    • Advanced NLP: Utilizes semantic understanding, sentiment analysis, and intent recognition to interpret user emotions and intent.
  3. Overview of Goose AI Agent Platform

    Goose is an AI agent platform that supports local and desktop environments with CLI capabilities. It automates engineering tasks such as code generation, debugging, testing, and deployment. It leverages the Model Context Protocol (MCP) to extend its functionality through external servers.
  4. Overview of Apertis AI Open-Source Model Services

    Apertis AI provides a variety of fine-tuned and optimized open-source large language model (LLM) services. They offer specialized versions of models from leading technology companies, tailored for business environments and diverse client requirements.
  5. Overview of Kilo Code features

    Kilo Code is a VS Code extension enhanced by MCP (Model Context Protocol) that provides AI-driven capabilities for code generation, debugging, project management, and database analysis. Key features include:

    • Code Generation: Creating code from natural language.
    • Database Analysis: Analyzing structures and relationships.
    • SQL Optimization: Generating and optimizing SQL queries.
    • Project Management: Organizing project files.
    • Refactoring: Improving code quality and structure.
    • Documentation: Creating codebase documentation.
  6. Manage request and fallback timeouts

    Apertis uses a two-layer timeout architecture:

    1. Total Request Timeout (X-Timeout header): Caps the entire request lifecycle, including channel retries and model fallbacks. Default: 60s.
    2. Per-Model Fallback Timeout (fallback_timeout parameter): Controls how long to wait for an individual fallback model before trying the next. Default: 15s.

    Interaction: The X-Timeout budget is the absolute limit. If channel retries consume part of this budget, the remaining time is available for fallback models. If fallback_timeout exceeds the remaining total budget, it is automatically reduced to fit the remaining time. For streaming requests, timers stop once the upstream starts sending data.

  7. Access AI models via the Apertis unified API gateway

    Apertis provides a unified API gateway to access models from multiple providers, including OpenAI, Google, Anthropic, Meta, Microsoft, Mistral, Alibaba, NVIDIA, xAI, Amazon, DeepSeek, Perplexity, and Allen AI. The specific models available to a user are determined by their API key type. The full catalog of available models can be found on the Apertis Models page.
  8. Apertis Python SDK capabilities and supported models

    The Apertis Python SDK provides a unified, type-safe interface for multiple AI providers including OpenAI, Anthropic, Google, DeepSeek, and xAI. Key features include sync/async support, streaming, tool calling, embeddings, vision, audio, video, web search, reasoning, and document reranking.
  9. Apertis API endpoint overview

    The Apertis API provides the following capabilities:

    • Text Generation: Chat Completions (OpenAI-compatible), Responses API (OpenAI format), and Messages API (Anthropic format).
    • Multimodal: Vision (image understanding), Image Generation, Audio (STT/TTS), and Video understanding.
    • Utilities: Billing Credits for checking subscription quota and remaining credits.
  10. Manage Personal and Team Organizations

    Organizations provide a centralized dashboard for managing shared API usage, billing, members, projects, API keys, and access control.

    • Personal Organizations: Every account has one default Personal organization. The owner is permanent and cannot leave or remove themselves. Owners can invite/remove other members; removing a member disables their organization-scoped API keys and admin keys.
    • Team Organizations: Separate shared workspaces. By default, users can create up to 5 team organizations.
  11. Understand how Apertis context compression works

    Context compression automatically summarizes older conversation history to reduce token usage and cost while preserving recent context. This process happens at the gateway level and is transparent to the application.

    The compression workflow follows these steps:

    1. Token threshold check: Triggers only when the conversation exceeds a configurable token threshold.
    2. Message segmentation: Splits messages into system prompts, compressible history, and recent turns (which are always preserved).
    3. Cost-effectiveness check: Skips compression if the cost of the compression model exceeds estimated savings.
    4. Summarization: Older messages are summarized using a lightweight model (e.g., gpt-4.1-mini, claude-haiku-4.5, or gemini-3-flash-preview).
    5. Injection: The summary replaces older messages, while recent turns remain verbatim.
  12. Configure task and budget parameters for model recommendations

    The /v1/recommend endpoint accepts two query parameters to determine the recommended model:

    Task Types (task - Required):

    • coding: Multi-file edits, debugging, code review, architecture.
    • long-context: Large codebases, long documents, multi-file reasoning.
    • fast-chat: Customer support, simple Q&A, chat workloads.
    • reasoning: Math, logic, structured problem solving.
    • vision: Images, diagrams, screenshots, UI understanding.

    Budget Tiers (budget - Optional, defaults to medium):

    • low: Cheapest valid candidate for the task (ideal for cost-sensitive background jobs).
    • medium: Editorial pick; the best balance of quality and cost.
    • high: Most capable candidate, regardless of price (ideal for user-facing interactive tasks).