Skip to content

Migrate to Python 3.11 for TIMO services#286

Open
rodneykinney wants to merge 2 commits into
mainfrom
python39-migration
Open

Migrate to Python 3.11 for TIMO services#286
rodneykinney wants to merge 2 commits into
mainfrom
python39-migration

Conversation

@rodneykinney

@rodneykinney rodneykinney commented Feb 23, 2026

Copy link
Copy Markdown
Member

Summary

Migrates five TIMO model configurations from Python 3.8/3.10 to Python 3.11 to resolve compatibility issues with modern pip and build tools.

Changes

  • Update python_version in src/ai2_internal/config.yaml to "3.11" for variants:
    • layout_parser (3.8 → 3.11, fixes layout-parser-v0 service)
    • bibentry_predictor_mmda (3.8 → 3.11)
    • citation_mentions (3.8 → 3.11)
    • dwp-heuristic (3.8 → 3.11)
    • svm-word-predictor (3.10 → 3.11)
  • Bump package version from 0.9.18 to 0.9.19 in pyproject.toml

Context

This is part of the migration effort to resolve Python 3.8 compatibility issues documented in https://github.com/allenai/scholar/issues/41682. Python 3.8 is no longer supported by modern pip installers (requires 3.9+), causing TIMO service build failures.

Critical: The layout-parser-v0 service is experiencing high latency issues (p50 > 120s) which may be related to the failed builds and outdated Python version.

Why Python 3.11?

  • Better performance (10-60% faster than 3.8)
  • Longer support lifecycle (security updates until October 2027)
  • Modern language features and improved error messages
  • Already supported by TIMO infrastructure (min version is 3.8)

Testing

  • Verify package builds with Python 3.11
  • Run integration tests for all five variants
  • Publish config to TIMO registry after merge (version 0.9.19)
  • Update timo-services to reference new version for all five services
  • Deploy and verify all services, prioritizing layout-parser-v0

Related Services

  • layout-parser-v0 (HIGH PRIORITY)
  • citation_mentions_v0
  • bibentry-predictor-mmda-v0
  • dwp-v1
  • word-predictor-v1

🤖 Generated with Claude Code

- Update python_version in config.yaml from 3.8 to 3.11 for variants:
  - layout_parser
  - bibentry_predictor_mmda
  - citation_mentions
  - dwp-heuristic
- Bump package version from 0.9.18 to 0.9.19

This resolves Python 3.8 compatibility issues with modern pip
and addresses scholar#41682 layout-parser latency problems.

Python 3.11 chosen for better performance and longer support lifecycle.

Affects 4 TIMO services:
- layout-parser-v0
- citation_mentions_v0
- bibentry-predictor-mmda-v0
- dwp-v1

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
@rodneykinney rodneykinney changed the title Migrate to Python 3.9 for TIMO services Migrate to Python 3.11 for TIMO services Feb 24, 2026
- Update python_version from 3.10 to 3.11 for svm-word-predictor variant
- Part of Python 3.9/3.10 to 3.11 migration effort

Affects word-predictor-v1 TIMO service.

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant