{"id":32929248,"url":"https://github.com/hiroshitanaka-creator/po_core","last_synced_at":"2026-05-15T08:02:17.315Z","repository":{"id":323272668,"uuid":"1088127973","full_name":"hiroshitanaka-creator/Po_core","owner":"hiroshitanaka-creator","description":"Po_core is a philosophy-driven AI with 42 philosophers onboard for ethically responsible, context-aware replies. It doesn’t optimize for statistical accuracy; it deliberates—turning existence, ethics, and meaning into operational tensors. Pigs can’t fly? Philosophy balloon. 🐷🎈 https://independent.academia.edu/僕僕","archived":false,"fork":false,"pushed_at":"2026-05-14T09:24:56.000Z","size":11107,"stargazers_count":3,"open_issues_count":70,"forks_count":1,"subscribers_count":3,"default_branch":"main","last_synced_at":"2026-05-14T11:29:28.481Z","etag":null,"topics":["ai","artificial-intelligence","docs","ethics","existentialism","explainable-ai","llm","nlp","phenomenology","philosophy","po-core","pytorch","pytorch-implementation","responsible-ai","sartre","tensors","viewer","visualization"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"agpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/hiroshitanaka-creator.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":"audit/00_baseline/baseline_truth.md","citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":"ROADMAP_FINAL_FORM.md","authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":"AGENTS.md","dco":null,"cla":null}},"created_at":"2025-11-02T11:20:58.000Z","updated_at":"2026-05-14T09:25:01.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/hiroshitanaka-creator/Po_core","commit_stats":null,"previous_names":["hiroshitanaka-creator/po_core"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/hiroshitanaka-creator/Po_core","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hiroshitanaka-creator%2FPo_core","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hiroshitanaka-creator%2FPo_core/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hiroshitanaka-creator%2FPo_core/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hiroshitanaka-creator%2FPo_core/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hiroshitanaka-creator","download_url":"https://codeload.github.com/hiroshitanaka-creator/Po_core/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hiroshitanaka-creator%2FPo_core/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33058965,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-13T13:14:54.681Z","status":"online","status_checked_at":"2026-05-15T02:00:06.351Z","response_time":103,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai","artificial-intelligence","docs","ethics","existentialism","explainable-ai","llm","nlp","phenomenology","philosophy","po-core","pytorch","pytorch-implementation","responsible-ai","sartre","tensors","viewer","visualization"],"created_at":"2025-11-11T11:19:57.330Z","updated_at":"2026-05-15T08:02:17.303Z","avatar_url":"https://github.com/hiroshitanaka-creator.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Po_core\n\n最優先ルール（単一真実）：[docs/厳格固定ルール.md](https://github.com/hiroshitanaka-creator/Po_core/blob/main/docs/厳格固定ルール.md)\n最新進捗：[docs/status.md](https://github.com/hiroshitanaka-creator/Po_core/blob/main/docs/status.md)\n\n**Philosophy-Driven AI: When Pigs Fly**\n\n\u003e *A frog in a well may not know the ocean, but it can know the sky.*\n\n[![PyPI version](https://img.shields.io/pypi/v/po-core-flyingpig)](https://pypi.org/project/po-core-flyingpig/)\n[![License: AGPL v3](https://img.shields.io/badge/License-AGPL%20v3-blue.svg)](./LICENSE)\n[![Status: Package%20metadata%20marks%20beta](https://img.shields.io/badge/Status-Package%20metadata%20marks%20beta-blue.svg)]()\n\n---\n\n## What is Po_core?\n\n**Po_core is a philosophy-driven AI decision-support system.** You give it a question; it returns structured options, reasons, counterarguments, uncertainty labels, and follow-up questions — all grounded in ethical deliberation.\n\n**What you get back:**\n\n- `proposal` — the winning response after multi-philosopher deliberation\n- `status` — `\"ok\"` or `\"blocked\"` (3-layer safety gate result)\n- `options` / `questions` — alternative framings and uncertainty probes\n- `trace` — full audit log of which reasoning paths were taken and why\n\n**What Po_core is not:**\n\n- Not a truth oracle — it does not claim factual correctness\n- Not an emotional-care chatbot — it provides structured reasoning, not emotional support\n- Not a replacement for medical, legal, or financial judgment\n\n---\n\n## Quick Start\n\n```bash\npip install po-core-flyingpig\n```\n\n```python\nfrom po_core import run\n\nresult = run(\"What is justice?\")\nprint(result[\"proposal\"])   # Winning philosopher's response\nprint(result[\"status\"])     # \"ok\" or \"blocked\"\n```\n\n\u003e **Install note:** Po_core pulls ML dependencies (`torch`, `sentence-transformers`, etc.). On a fresh environment the install may take several minutes. If `torch` or `sbert` are unavailable, the tensor backend falls back to `tfidf`/`basic` automatically — core deliberation still works.\n\n**Local development checkout:**\n\n```bash\ngit clone https://github.com/hiroshitanaka-creator/Po_core.git\ncd Po_core\npip install -e \".[dev]\"\n```\n\n---\n\n## Key Links\n\n| | |\n|---|---|\n| [Tutorial](./docs/TUTORIAL.md) | Step-by-step getting-started guide |\n| [Python API reference](#python-api) | `run()` / `run_case()` / `PoSelf` / `PoSelfResponse` |\n| [run_case API guide](./docs/RUN_CASE.md) | Structured case input → output_schema_v1 output |\n| [REST API](#rest-api) | FastAPI server + curl examples |\n| [Manifesto](./Po_core_Manifesto_When_Pigs_Fly.md) | Philosophy and motivation |\n| [Release state](https://github.com/hiroshitanaka-creator/Po_core/blob/main/docs/status.md) | Current version, evidence gaps, roadmap |\n| [Safety Guide](./docs/SAFETY.md) | W-ethics gate system |\n| [Discussions](https://github.com/hiroshitanaka-creator/Po_core/discussions) | Feedback welcome |\n\n---\n\n## Why the Deliberation Approach?\n\nCurrent AI optimizes for statistical accuracy — a brilliant parrot that understands nothing. Po_core asks a different question: **what if AI reasoned from philosophy, not just data?**\n\nThe differentiator: **42 philosophers** (Western, Eastern, African, Canadian) run as interacting tensors through a 10-step hexagonal pipeline. Each brings its own reasoning module. They compete, interfere, and reconcile — producing a Pareto-optimal proposal with a measurable ethical pressure signal instead of a single confident prediction. (The internal `dummy` slot is a compliance sentinel helper and must not be counted as one of the 42.)\n\nNo matter how many relationships we have, decisions are made alone. That's why Po_core exists — **to stand beside you when you must say \"Leave it to me.\"**\n\nRead the full story: [Manifesto](./Po_core_Manifesto_When_Pigs_Fly.md)\n\n---\n\n## Architecture\n\n**Hexagonal `run_turn` pipeline — 10 steps:**\n\n```\nMemoryRead → TensorCompute → SolarWill → IntentionGate → PhilosopherSelect\n→ PartyMachine → ParetoAggregate → ShadowPareto → ActionGate → MemoryWrite\n```\n\n**Three tensor metrics** measure the deliberation:\n\n| Metric | What it measures |\n|---|---|\n| FreedomPressureV2 (6D ML) | Choice, responsibility, urgency, ethics, social impact, authenticity |\n| Semantic Delta | Novelty of the input vs. memory history (1.0 = never seen, 0.0 = familiar) |\n| Blocked Tensor | Constraint / harm estimation |\n\n**Safety** is three-layered: `IntentionGate` (pre-deliberation) → `PolicyPrecheck` (mid-pipeline) → `ActionGate` (post-deliberation). SafetyMode transitions NORMAL → WARN → CRITICAL based on freedom_pressure thresholds.\n\nFor full source layout and component detail → [Architecture docs](./02_architecture) · [CLAUDE.md](./CLAUDE.md)\n\n---\n\n## Release State\n\nRepository target version is `1.1.0`; `1.0.3` is the latest published on PyPI. Package classifiers declare `Development Status :: 4 - Beta`.\n\nFor the complete evidence record, evidence gaps, and roadmap: **[docs/status.md](https://github.com/hiroshitanaka-creator/Po_core/blob/main/docs/status.md)**\n\n---\n\n## Installation\n\n```bash\n# From PyPI (recommended)\npython3 -m venv venv\nsource venv/bin/activate  # Windows: venv\\Scripts\\activate\npip install po-core-flyingpig\n\n# Specific version\npip install \"po-core-flyingpig==1.0.3\"\n\n# Local development\ngit clone https://github.com/hiroshitanaka-creator/Po_core.git\ncd Po_core\npip install -e \".[dev]\"\n```\n\n\u003e `requirements.txt` / `requirements-dev.txt` are repo-local convenience wrappers for a cloned checkout. External consumers should install from package metadata, not from those editable wrappers.\n\n---\n\n## Python API\n\nUse `run_case(case: dict)` when you need output_schema_v1-conformant structured decision-support output. Use `run(user_input: str)` when you want the raw philosopher pipeline result.\n\n### Simple API (Recommended)\n\n```python\nfrom po_core import run\n\nresult = run(user_input=\"Should AI have rights?\")\n\nprint(result[\"status\"])       # \"ok\" or \"blocked\"\nprint(result[\"request_id\"])   # Unique request ID\nprint(result[\"proposal\"])     # Winning philosopher's response\n\n# Optional explicit philosopher allowlist\nsubset = run(user_input=\"Should AI have rights?\", philosophers=[\"kant\"])\n```\n\n### PoSelf API (Rich Response)\n\n```python\nfrom po_core import PoSelf, PoSelfResponse\n\npo_self = PoSelf(philosophers=[\"aristotle\", \"confucius\"])\nresponse: PoSelfResponse = po_self.generate(\"Should AI have rights?\")\n\nprint(response.text)               # Combined response text\nprint(response.consensus_leader)   # Winning philosopher name\nprint(response.philosophers)       # Selected philosopher list\nprint(response.metrics)            # {\"freedom_pressure\": ..., \"semantic_delta\": ..., ...}\nprint(response.metadata[\"status\"]) # \"ok\" or \"blocked\"\n\n# Trace inspection\nprint(response.log[\"events\"])      # Full trace event stream\n\n# Serialization\nd = response.to_dict()\nrestored = PoSelfResponse.from_dict(d)\n```\n\n### Structured Output (synthesis_report)\n\n```bash\nexport PO_STRUCTURED_OUTPUT=1\npython scripts/observe_device.py \"転職するべき？家族とキャリアのトレードオフが悩み\"\n```\n\n### Legacy Note\n\n`run_ensemble()` was removed in v0.3. Use `po_core.run()` or `PoSelf.generate()` instead.\n\n---\n\n## CLI\n\n```bash\npo-core version\npo-core status\npo-core --help\n\npo-self --help\npo-trace --help\npo-interactive --help\npo-experiment --help\n```\n\nSource checkout example:\n\n```bash\npython examples/po_party_demo.py --help\n```\n\n---\n\n## REST API\n\n```bash\n# Start with recommended auth posture\nexport PO_API_KEY=dev-secret-key\npython -m po_core.app.rest\n# → http://localhost:8000  (OpenAPI docs at /docs)\n\n# Reason\ncurl -X POST http://localhost:8000/v1/reason \\\n     -H \"X-API-Key: dev-secret-key\" \\\n     -H \"Content-Type: application/json\" \\\n     -d '{\"input\": \"What is justice?\", \"philosophers\": [\"kant\"]}'\n\n# Streaming (SSE)\ncurl -N http://localhost:8000/v1/reason/stream \\\n     -X POST -H \"X-API-Key: dev-secret-key\" \\\n     -H \"Content-Type: application/json\" \\\n     -d '{\"input\": \"What is freedom?\"}'\n\n# Philosopher manifest\ncurl -H \"X-API-Key: dev-secret-key\" http://localhost:8000/v1/philosophers\n\n# Health (no auth required)\ncurl http://localhost:8000/v1/health\n```\n\n**Auth defaults:** Keep `PO_SKIP_AUTH=false` and set a non-empty `PO_API_KEY`. If both are unset, startup fails fast by design. `PO_SKIP_AUTH=true` is acceptable only for short-lived local development.\n\n**Key env vars** (see `.env.example` for full list):\n\n| Variable | Default | Description |\n|---|---|---|\n| `PO_API_KEY` | `\"\"` | API key; blank causes startup failure when `PO_SKIP_AUTH=false` |\n| `PO_SKIP_AUTH` | `false` | Set `true` only for short-lived local dev |\n| `PO_CORS_ORIGINS` | `http://localhost,http://127.0.0.1,http://localhost:3000,http://127.0.0.1:3000` | Comma-separated allowed origins; localhost-only by default |\n| `PO_RATE_LIMIT_PER_MINUTE` | `60` | Per-IP rate limit |\n| `PO_PORT` | `8000` | Server port |\n| `PO_PHILOSOPHER_EXECUTION_MODE` | `process` | Safe REST default; `thread` requires `PO_ALLOW_UNSAFE_THREAD_EXECUTION=true` |\n\n---\n\n## Docker\n\n```bash\ncp .env.example .env\ndocker compose up\n# API: http://localhost:8000\n# Swagger: http://localhost:8000/docs\n```\n\n---\n\n## A/B Experiments\n\n```bash\npo-experiment list\npo-experiment analyze exp_001_safety_weight_sweep\npo-experiment promote exp_001_safety_weight_sweep\npo-experiment rollback\n```\n\nPo_core's Pareto weights are config-driven (`pareto_table.yaml`) and fully externalized. Tune philosophy without code changes; `config_version` is tracked in all TraceEvents for audit.\n\n---\n\n## Documentation\n\n| Document | Description |\n|---|---|\n| [docs/spec/prd.md](./docs/spec/prd.md) | Product Requirements Document |\n| [docs/spec/srs_v0.1.md](./docs/spec/srs_v0.1.md) | Software Requirements Specification (18 FR/NFR IDs) |\n| [docs/spec/output_schema_v1.json](./docs/spec/output_schema_v1.json) | JSON Schema — contract for all structured output |\n| [docs/spec/test_cases.md](./docs/spec/test_cases.md) | 10 acceptance tests (AT-001〜AT-010) |\n| [docs/spec/traceability.md](./docs/spec/traceability.md) | Traceability matrix |\n| [docs/ENGINE_TRACE_CONTRACT.md](./docs/ENGINE_TRACE_CONTRACT.md) | Engine trace event contract (TensorComputed, SafetyModeInferred, Pareto events, DecisionEmitted) |\n| [docs/SAFETY.md](./docs/SAFETY.md) | W-ethics safety system |\n| [docs/TUTORIAL.md](./docs/TUTORIAL.md) | Getting started guide |\n| [docs/VISUALIZATION_GUIDE.md](./docs/VISUALIZATION_GUIDE.md) | Tension maps and pressure display |\n| [01_specifications/](./01_specifications) | Technical specifications (120+ docs EN/JP) |\n| [02_architecture/](./02_architecture) | System design documents |\n| [04_modules/](./04_modules) | Component documentation |\n| [05_research/](./05_research) | Academic papers and analysis |\n\n---\n\n## Contributing\n\nWe welcome philosophers, engineers, designers, and skeptics.\n\n**Contribution tracks:**\n\n- **AI Track** — Start with `/04_modules` and CLI. Labels: `ai-easy`, `good first issue`\n- **Philosophy Track** — Start with `/05_research` and `/glossary`. Label: `phil-easy`\n- **Bridge Track** — Translate checklists to scoring functions. Label: `bridge`\n\nFlying Pig Philosophy applies: hypothesize boldly, verify rigorously, revise gracefully.\n\nSee [CONTRIBUTING.md](./CONTRIBUTING.md) for guidelines.\n\n---\n\n## Research\n\n- \"Philosophical Tensor-Based AI Architecture\" (in preparation)\n- 120+ Technical Specifications in [/docs/](./docs/) and [/01_specifications/](./01_specifications/)\n\n```bibtex\n@software{po_core2024,\n  author = {Flying Pig Philosopher},\n  title = {Po_core: Philosophy-Driven AI System},\n  year = {2026},\n  url = {https://github.com/hiroshitanaka-creator/Po_core}\n}\n```\n\n---\n\n## License\n\nPo_core uses **dual licensing**:\n\n| Use case | License |\n|---|---|\n| Personal / Academic / Research / OSS (AGPLv3-compliant) | **Free** — [AGPLv3](./LICENSE) |\n| Commercial / Proprietary / SaaS without source disclosure | **Commercial License required** |\n\nFor commercial licensing: flyingpig0229+github@gmail.com\nSee [COMMERCIAL_LICENSE.md](./COMMERCIAL_LICENSE.md) for details.\n\nCopyright (c) 2024 Flying Pig Project\n\n\u003e \"If you deny possibilities for pigs, don't eat pork.\"\n\n---\n\n## Author\n\n**Flying Pig Philosopher** — Looking up at the sky from the bottom of a well\n\nBuilt by an independent researcher who asked: *\"What are AI's possibilities, not its limits?\"*\n\n- Contact: \u003cflyingpig0229+github@gmail.com\u003e\n- Read the full story: [Manifesto](./Po_core_Manifesto_When_Pigs_Fly.md)\n\n---\n\n## Acknowledgments\n\n- **ChatGPT, Gemini, Grok, Claude** — My companions throughout this journey\n- **BUMP OF CHICKEN** — For reminding us that even when we say \"Leave it to me,\" we're all a little scared\n- **Every philosopher** who dared to ask \"What does it mean to be?\"\n- **You** — For believing pigs can fly\n\n---\n\nThe pig has clearance for takeoff.\n\n**Po_core: When you must say \"Leave it to me,\" we stand beside you.**\n\n\u003cp align=\"center\"\u003e\n  \u003ci\u003e\"A frog in a well may not know the ocean, but it can know the sky.\"\u003c/i\u003e\n\u003c/p\u003e\n\n---\n\n⚠️ **WARNING: THIS IS THE ORIGINAL Po_core REPOSITORY**\n\n- **Official sources**:\n  - GitHub: [hiroshitanaka-creator/Po_core](https://github.com/hiroshitanaka-creator/Po_core)\n  - Note.com: [tensor mania](https://note.com/tender_flea2177)\n  - Academia.edu: [僕 僕](https://independent.academia.edu/%E5%83%95%E5%83%95)\n\n- DMCA申請中 (Reference ID: #4124875)\n- Any full copy, license rewrite (MIT), or impersonation (flying_pig) will be reported and removed.\n- Commercial use requires separate license. Unauthorized copies detected via tensor mania series.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhiroshitanaka-creator%2Fpo_core","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhiroshitanaka-creator%2Fpo_core","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhiroshitanaka-creator%2Fpo_core/lists"}