v6.9.7: PyPI + Docker 工程化 — pip install + docker compose up 一键部署
feat(pypi): publish-pypi.yml workflow (tag-triggered, OIDC trusted publishing) feat(docker): Dockerfile + docker-compose.yml (API :5200 + Web :5300) feat(ci): docker-publish.yml workflow (ghcr.io, tag-triggered) chore: version unified to v6.9.6 (pyproject/__init__/SKILL/README) chore: MANIFEST.in + scripts/__init__.py for pip install support chore: pyproject.toml updated packages.find to include scripts/ chore: README.md status section refreshed, P0/P1 updated Verified: wheel build + twine check PASSED, pip install + import OK
This commit is contained in:
@@ -0,0 +1,52 @@
|
||||
name: Build & Push Docker Image
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- 'v*'
|
||||
workflow_dispatch:
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
packages: write
|
||||
|
||||
env:
|
||||
REGISTRY: ghcr.io
|
||||
IMAGE_NAME: ${{ github.repository }}
|
||||
|
||||
jobs:
|
||||
build-and-push:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v3
|
||||
|
||||
- name: Log in to GitHub Container Registry
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: ${{ env.REGISTRY }}
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Extract metadata
|
||||
id: meta
|
||||
uses: docker/metadata-action@v5
|
||||
with:
|
||||
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
|
||||
tags: |
|
||||
type=semver,pattern={{version}}
|
||||
type=semver,pattern={{major}}.{{minor}}
|
||||
type=ref,event=branch
|
||||
type=sha,format=short
|
||||
|
||||
- name: Build and push
|
||||
uses: docker/build-push-action@v5
|
||||
with:
|
||||
context: .
|
||||
push: true
|
||||
tags: ${{ steps.meta.outputs.tags }}
|
||||
labels: ${{ steps.meta.outputs.labels }}
|
||||
cache-from: type=gha
|
||||
cache-to: type=gha,mode=max
|
||||
@@ -0,0 +1,36 @@
|
||||
name: Publish to PyPI
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- 'v*'
|
||||
workflow_dispatch:
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
id-token: write
|
||||
|
||||
jobs:
|
||||
build-and-publish:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Set up Python
|
||||
uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version: '3.11'
|
||||
|
||||
- name: Install build tools
|
||||
run: pip install build twine
|
||||
|
||||
- name: Build package
|
||||
run: python -m build
|
||||
|
||||
- name: Check package metadata
|
||||
run: twine check dist/*
|
||||
|
||||
- name: Publish to PyPI
|
||||
uses: pypa/gh-action-pypi-publish@release/v1
|
||||
with:
|
||||
skip-existing: true
|
||||
+49
@@ -0,0 +1,49 @@
|
||||
# ─── Jyotish Vedic Astrology Docker Image ───
|
||||
# Build: docker build -t jyotish-vedic .
|
||||
# Run: docker run -p 5200:5200 jyotish-vedic
|
||||
# API: http://localhost:5200/api/health
|
||||
|
||||
FROM python:3.11-slim
|
||||
|
||||
LABEL org.opencontainers.image.title="jyotish-vedic-astrology"
|
||||
LABEL org.opencontainers.image.description="Vedic Astrology (Jyotish) calculation engine with AI-ready APIs"
|
||||
LABEL org.opencontainers.image.source="https://github.com/732642856/yinduzhanxing"
|
||||
LABEL org.opencontainers.image.licenses="MIT"
|
||||
|
||||
# ─── System deps ───
|
||||
RUN apt-get update && apt-get install -y --no-install-recommends \
|
||||
curl \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# ─── Python deps ───
|
||||
WORKDIR /app
|
||||
|
||||
COPY requirements.txt .
|
||||
RUN pip install --no-cache-dir -r requirements.txt
|
||||
|
||||
# ─── Application ───
|
||||
COPY jyotish_vedic/ ./jyotish_vedic/
|
||||
COPY scripts/ ./scripts/
|
||||
COPY jyotish-app/ ./jyotish-app/
|
||||
COPY mcp_server.py ./mcp_server.py
|
||||
COPY assets/ ./assets/
|
||||
|
||||
# ─── Verify installation ───
|
||||
RUN python -c "from jyotish_vedic import __version__; print(f'Jyotish v{__version__} ready')"
|
||||
|
||||
# ─── Ports ───
|
||||
# 5200: REST API server
|
||||
# 5300: jyotish-app static web frontend
|
||||
EXPOSE 5200 5300
|
||||
|
||||
# ─── Health check ───
|
||||
HEALTHCHECK --interval=30s --timeout=5s --start-period=10s --retries=3 \
|
||||
CMD curl -f http://localhost:5200/api/health || exit 1
|
||||
|
||||
# ─── Entry point: start both API + web frontend ───
|
||||
CMD ["sh", "-c", "\
|
||||
echo 'Starting Jyotish API server on :5200...' && \
|
||||
python3 scripts/jyotish_api_server.py --port 5200 & \
|
||||
echo 'Starting jyotish-app on :5300...' && \
|
||||
cd jyotish-app && python3 -m http.server 5300 --bind 0.0.0.0 & \
|
||||
wait"]
|
||||
+26
@@ -0,0 +1,26 @@
|
||||
include README.md
|
||||
include CHANGELOG.md
|
||||
include LICENSE
|
||||
include requirements.txt
|
||||
include requirements-dev.txt
|
||||
include mcp_server.py
|
||||
recursive-include scripts *.py
|
||||
recursive-include scripts *.json
|
||||
recursive-include scripts *.csv
|
||||
recursive-include jyotish_vedic *.py
|
||||
recursive-include jyotish_vedic *.json
|
||||
recursive-include jyotish_vedic *.md
|
||||
recursive-include jyotish-app *
|
||||
recursive-include tests *.py
|
||||
recursive-include tests *.json
|
||||
recursive-include assets *
|
||||
prune references
|
||||
prune benchmarks
|
||||
prune .github
|
||||
prune docs
|
||||
prune skills
|
||||
prune __pycache__
|
||||
prune .pytest_cache
|
||||
prune .ruff_cache
|
||||
prune .hypothesis
|
||||
prune **/__pycache__
|
||||
@@ -266,10 +266,15 @@ Examples:
|
||||
|
||||
## Project Status
|
||||
|
||||
**Current version:** `v6.1.10-dk-rtn-theme-bridge`
|
||||
**Current version:** `v6.9.6`
|
||||
|
||||
### Recently Completed
|
||||
|
||||
- `v6.9.6` — Field mapping fixes (degree→degree_in_sign + toFixed null safety); PyPI publishing config.
|
||||
- `v6.9.5` — birth_info null safety + API field mapping fixes.
|
||||
- `v6.9.4` — AI interpretation integration (GPT relay via copse.top); api-bridge.js bundled into public/.
|
||||
- `v6.9.3` — 35 Dasha systems, 405+ Yoga rules, KP complete system, Prashna, 16-factor synastry, Remedies, Sahams 36, Sudarshana, PMC, Tajika.
|
||||
- `v6.1.12` — Chara Dasha KN Rao Method rewrite, PyJHora benchmark 95.83% PASS.
|
||||
- `v6.1.10` — Darakaraka deep reader wired into `full-reading.modules.jaimini.darakaraka`; thematic reports now consume real DK and Rashi Tulya Navamsa evidence.
|
||||
- `v6.1.9` — Public/sanitized benchmark suite, competitive research, coverage roadmap and PDF validation methodology added.
|
||||
- `v6.1.8` — Yoga validation reached F1=95.22% (FP=36, FN=63); thematic reports consume real `full-reading.modules` evidence.
|
||||
@@ -278,20 +283,18 @@ Examples:
|
||||
|
||||
### Actively Working On (P0)
|
||||
|
||||
1. **Chara Dasha rewrite** — align with PyJHora KN Rao method (target: ≥95% match)
|
||||
1. **PyPI release** — Package validated; needs `twine upload` and GitHub Actions tag-trigger
|
||||
2. **Shadbala external calibration** — align with JHora / PyJHora / BV Raman
|
||||
3. **Darakaraka / RTN external benchmark** — v6.1.10 has wired the modules; next step is traditional case validation and evidence ranking
|
||||
3. **Test expansion** — from 50 smoke tests to 200+ unit/regression tests
|
||||
4. **KP Sub-Lord full implementation** — unequal Vimshottari subdivisions
|
||||
5. **Bhava Chalit complete** — cusp-based planet reassignment
|
||||
6. **Sudarshana Chakra traditional** — Sun/Moon/Lagna reference points
|
||||
|
||||
### Next (P1)
|
||||
|
||||
- Benchmark harness (PyJHora output comparison)
|
||||
- Docker image (Dockerfile + docker-compose.yml created, needs push)
|
||||
- English documentation completion
|
||||
- Docker image
|
||||
- MCP Server endpoint
|
||||
- GitHub Actions CI
|
||||
- Multi-Ayanamsa support (Lahiri + Raman + KP + custom)
|
||||
|
||||
---
|
||||
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
---
|
||||
name: jyotish-vedic-astrology
|
||||
version: 6.9.3
|
||||
version: 6.9.6
|
||||
description: 印度占星(Jyotish)专业解盘与推运系统。核心能力:PDF星盘输入→严谨解盘→精确推运应期输出。35种Dasha、405+Yoga规则、KP完整系统、Prashna卜卦、16因子合盘、Remedies补救、Sahams 36种、Sudarshana三参考点、PMC完整检测、Tajika年度星盘、案例验证+误区纠正。触发词:印度占星、吠陀占星、Jyotish、解盘、推运、星盘分析、Dasha、Transit、Nakshatra、Yoga。GitHub: https://github.com/732642856/yinduzhanxing
|
||||
---
|
||||
|
||||
# 印度占星专业解盘与推运系统
|
||||
|
||||
> **版本**:v6.9.3 | **详细变更**:`CHANGELOG.md`
|
||||
> **版本**:v6.9.6 | **详细变更**:`CHANGELOG.md`
|
||||
> **全局排名**:技术上并列全球第1(35种Dasha、405+Yoga、KP完整、Prashna、Remedies、独有中文引擎)
|
||||
> **执行总控**:`references/quick-reference-guide.md`
|
||||
> **严格路由**:`references/strict-workflow-router.md`(涉及事业/婚恋/财务/应期/技法验证时必须优先读取)
|
||||
> **机器注册表**:`references/technique_registry.json` + `scripts/audit_capabilities.py`
|
||||
|
||||
## v6.9.3 核心能力
|
||||
## v6.9.6 核心能力
|
||||
|
||||
| 维度 | 数据 |
|
||||
|------|:--:|
|
||||
@@ -25,13 +25,13 @@ description: 印度占星(Jyotish)专业解盘与推运系统。核心能力
|
||||
| 合盘 | 16因子36分制(Ashtakoot+Kuta) |
|
||||
| 补救 | 5类(宝石/咒语/捐赠/斋戒/Dosha专项) |
|
||||
| 自动化测试 | 50/50 (100%) |
|
||||
| Git commits | v6.1.12→v6.9.3 共19个 |
|
||||
| Git commits | v6.1.12→v6.9.6 共19个 |
|
||||
|
||||
**独有能力**:中文AI解读引擎、Career/Love结构化分析、验前事反推管道、误区自动纠正、名人+普通人案例双轨验证。
|
||||
|
||||
## Yoga 逻辑验证指标
|
||||
|
||||
| 指标 | v6.0.45(旧基线) | v6.9.3(当前) |
|
||||
| 指标 | v6.0.45(旧基线) | v6.9.6(当前) |
|
||||
|---|---:|---:|
|
||||
| Precision | 83.26% | **96.48%** |
|
||||
| Recall | 91.52% | **93.99%** |
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
# ─── Jyotish Vedic Astrology Compose Stack ───
|
||||
# Start: docker compose up -d
|
||||
# Stop: docker compose down
|
||||
# API: http://localhost:5200/api/health
|
||||
# Web App: http://localhost:5300
|
||||
|
||||
version: "3.9"
|
||||
|
||||
services:
|
||||
jyotish:
|
||||
build: .
|
||||
container_name: jyotish-vedic
|
||||
ports:
|
||||
- "5200:5200" # REST API
|
||||
- "5300:5300" # jyotish-app web frontend
|
||||
restart: unless-stopped
|
||||
healthcheck:
|
||||
test: ["CMD", "curl", "-f", "http://localhost:5200/api/health"]
|
||||
interval: 30s
|
||||
timeout: 5s
|
||||
retries: 3
|
||||
start_period: 10s
|
||||
environment:
|
||||
- TZ=Asia/Shanghai
|
||||
- PYTHONUNBUFFERED=1
|
||||
volumes:
|
||||
# Mount your own chart data / celebrity cases (optional)
|
||||
- ./tests/celebrity_cases.json:/app/tests/celebrity_cases.json:ro
|
||||
@@ -24,7 +24,7 @@ _scripts_dir = os.path.join(_repo_root, "scripts")
|
||||
if _scripts_dir not in sys.path:
|
||||
sys.path.insert(0, _scripts_dir)
|
||||
|
||||
__version__ = "6.1.10"
|
||||
__version__ = "6.9.6"
|
||||
__all__ = [
|
||||
"calculate_chart",
|
||||
"calculate_dasha",
|
||||
|
||||
+6
-3
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
||||
|
||||
[project]
|
||||
name = "jyotish-vedic-astrology"
|
||||
version = "6.1.10"
|
||||
version = "6.9.6"
|
||||
description = "Comprehensive Jyotish (Vedic Astrology) calculation engine with AI-ready APIs"
|
||||
readme = "README.md"
|
||||
license = "MIT"
|
||||
@@ -39,6 +39,9 @@ dev = [
|
||||
"build>=0.9",
|
||||
"twine>=4.0",
|
||||
]
|
||||
api = [
|
||||
"mcp>=1.0",
|
||||
]
|
||||
|
||||
[project.scripts]
|
||||
jyotish = "jyotish_vedic.cli:main"
|
||||
@@ -54,8 +57,8 @@ Changelog = "https://github.com/732642856/yinduzhanxing/blob/main/CHANGELOG.md"
|
||||
|
||||
[tool.setuptools.packages.find]
|
||||
where = ["."]
|
||||
include = ["jyotish_vedic*"]
|
||||
exclude = ["tests*", "docs*", "jyotish-app*", "benchmark*", "references*"]
|
||||
include = ["jyotish_vedic*", "scripts*"]
|
||||
exclude = ["tests*", "docs*", "jyotish-app*", "benchmark*", "benchmarks*", "references*", "skills*", "assets*"]
|
||||
|
||||
[tool.setuptools.package-data]
|
||||
jyotish_vedic = ["*.json", "*.md", "*.csv", "*.db"]
|
||||
|
||||
Reference in New Issue
Block a user