Skip to main content

Local-first research framework for evidence-grounded idea generation.

Project description

Principia V1.3

Principia V1.3 is a local-first Python framework for research search, paper feature extraction, evidence-grounded idea generation, and prior-idea comparison.

The import package is principia. The initial PyPI distribution name is principia-ai because the principia distribution name is currently occupied on PyPI. If that ownership issue is resolved later, the import API remains unchanged.

Install

pip install principia-ai

For notebooks:

pip install principia-ai ipykernel
python -m ipykernel install --user --name principia-v13-python --display-name "Python 3.12 (Principia V1.3)"

Quickstart

import principia as pc

API_key = "sk-your-key-here"
goal = "provide real-time, calibrated, actionable process quality control for autonomous coding agents operating on large-scale repositories"

ws = pc.Workspace(
    "./principia_project",
    llm_config=pc.siliconflow_config(API_key, timeout=420, max_retries=2),
)

works = ws.research.search(goal, target_count=50)
features = ws.research.extract(
    works[:20],
    model="siliconflow:deepseek-ai/DeepSeek-V4-Pro",
    overwrite=False,
)
selected_evidence = pc.select_evidence(features)
idea = ws.ideas.generate(
    selected_evidence,
    user_note=goal,
    mode="calculus",
    model="siliconflow:Qwen/Qwen3.5-397B-A17B",
)
comparison = ws.ideas.compare(idea, features, model="siliconflow:Qwen/Qwen3.5-397B-A17B")

export_path = ws.export(
    goal=goal,
    works=works,
    features=features,
    idea=idea,
    comparison=comparison,
)

What Principia Provides

  • Hybrid research search over OpenAlex, Crossref, and arXiv.
  • DOI/arXiv/OpenAlex/title deduplication with peer-reviewed venue promotion.
  • Structured extraction of ideas, principles, baselines, benchmarks, takeaways, and result facts.
  • Evidence selection through pc.select_evidence(...).
  • Idea generation modes: standard, calculus, and scidialect_evo.
  • Generation modes are internal strategies, not evidence; generated source_evidence is grounded to selected work/feature IDs.
  • Prior-idea comparison using lexical shortlisting plus the configured LLM.
  • Notebook and terminal progress with ETA, heartbeat updates during long LLM calls, cancellation, and resume-by-cache behavior.
  • Local SQLite storage with visible user-facing exports.

Workspace Layout

Principia creates visible files under the workspace root:

principia_project/
  README.md
  principia_outputs/
    latest/
      idea.md
      result.json
      works.json
    exports/
      <idea_id>/
        idea.md
        result.json
        works.json
  .principia/
    principia.sqlite
    artifacts/
      source_json/
      exports/
      pdfs/
      cache/

The .principia/ folder stores internal SQLite state, cache data, and canonical artifacts. The visible principia_outputs/ folder mirrors the latest readable outputs for inspection.

Tutorial And Docs

The official tutorial contains no real API key and no executed outputs. Replace YOUR_SILICONFLOW_API_KEY at runtime in your own local copy.

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

principia_ai-1.3.1.tar.gz (51.7 kB view details)

Uploaded Source

Built Distribution

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

principia_ai-1.3.1-py3-none-any.whl (44.9 kB view details)

Uploaded Python 3

File details

Details for the file principia_ai-1.3.1.tar.gz.

File metadata

  • Download URL: principia_ai-1.3.1.tar.gz
  • Upload date:
  • Size: 51.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.7

File hashes

Hashes for principia_ai-1.3.1.tar.gz
Algorithm Hash digest
SHA256 7cb05a939b4f8f0c0c4bc8195e2eb8dd4f03a7ae6e13e1eeb6d6b52caf2325ad
MD5 77f54a859ee2f4ec7f2e142722defb58
BLAKE2b-256 c68a3bd95f2876261a89f06a0de49e736abe9572d0041b65237ba9ea722af36c

See more details on using hashes here.

File details

Details for the file principia_ai-1.3.1-py3-none-any.whl.

File metadata

  • Download URL: principia_ai-1.3.1-py3-none-any.whl
  • Upload date:
  • Size: 44.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.7

File hashes

Hashes for principia_ai-1.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 1ae48b28aea820258fbd06655c5cd00c59071929ac48554426f3f333c0071d31
MD5 c33e35e3445d4292659ed4e448a0b4c5
BLAKE2b-256 7b7db1d54d271a87311b5041d056be411e69433ab2314fe9eccd5e748772c898

See more details on using hashes here.

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