google

    google/langextract

    A Python library for extracting structured information from unstructured text using LLMs with precise source grounding and interactive visualization.

    llm
    nlp
    gemini
    gemini-ai
    gemini-api
    gemini-flash
    gemini-pro
    Python
    Apache-2.0
    39.0K stars
    2.7K forks
    39.0K GitHub watchers
    Updated Oct 26, 2026
    View on GitHub

    Build with Backblaze B2

    SDKs, agent skills, IDE extensions, and reference pipelines from Backblaze Labs. All open source.

    Explore Backblaze Labs

    Loading star history...

    Where it stands

    Rank, growth pace and release cadence relative to everything GStars tracks.

    2 releases in the last 90 days, the latest 18 days ago, with 28 contributors on GitHub.

    Peaked at #1 in the weekly ranking the week of Feb 8, its best in the past year.

    Use Cases & Benefits

    • Extract structured information from unstructured text using LLMs with precise source grounding and interactive visualization.
    • Ensures reliable, schema-constrained outputs with exact source mapping and supports flexible LLMs including cloud and local models.
    • Use for extracting detailed entities and relationships from literary texts with traceable source highlights.
    • Use for structuring clinical notes and medical reports to identify medications, dosages, and related attributes.
    • Use for processing large documents or datasets with parallel extraction passes and interactive HTML visualizations for review.

    Should you depend on it?

    License terms, project hygiene and risks, from GitHub metadata and GStars' snapshots.

    License

    Apache 2.0

    Permissive: commercial use, modification and redistribution are allowed with attribution; includes an explicit patent grant from contributors.

    Community files

    • README: present
    • Contributing guide: present
    • Code of conduct: present

    Watch-outs

    No watch-outs from GStars' checks.

    General guidance from repository metadata, not legal advice. How we score

    From the README

    LangExtract is a Python library that uses LLMs to extract structured information from unstructured text documents based on user-defined instructions. It processes materials such as clinical notes or reports, identifying and organizing key details while ensuring the extracted data corresponds to the source text.

    Note: Using cloud-hosted models like Gemini requires an API key. See the API Key Setup section for instructions on how to get and configure your key.

    Extract structured information with just a few lines of code.

    Excerpt from the google/langextract README on GitHub (Apache-2.0 license). © its authors.Read the full README on GitHub

    Daily snapshots

    Stars gained per day, and how forks and open issues moved, from GStars' daily snapshots

    Aug 13: +10Sep 26: +22

    +1,128 stars over 90 days across 10 snapshot days; best day +22 on Sep 26.

    Forks

    2.7K+97

    Open issues

    121+2

    Compared with peers in LLM

    Fastest-growing repositories GStars tracks in this cohort for the week of Nov 1, by 7-day star growth

    google/langextract compared with LLM repositories by stars, 7-day star growth, health score and last release
    RepositoryStars+7dHealthLast release
    thedotmack/claude-mem113.6K+8.8K35today
    NVIDIA/auto-ontology7.5K+5.6K37—
    HKUDS/DeepTutor55.5K+5.5K655 days ago
    affaan-m/ECC297.9K+5.2K6335 days ago
    DietrichGebert/ponytail185.3K+5.1K607 days ago
    google/langextract39.0K—5318 days ago
    Category median113.6K+5.5K60—

    Also by google

    Other repositories from this maintainer that GStars tracks

    Discover Repositories

    Search across tracked repositories by name or description