add Visa timeline calculator and mode integration for international job seekers#200
Open
minwoo-data wants to merge 39 commits intosantifer:mainfrom
Open
add Visa timeline calculator and mode integration for international job seekers#200minwoo-data wants to merge 39 commits intosantifer:mainfrom
minwoo-data wants to merge 39 commits intosantifer:mainfrom
Conversation
- download-uscis.mjs with --dry-run, --force, --year CLI modes - Bundled sample CSV with 17 rows of realistic multi-year H-1B data - Quarterly staleness detection (90-day threshold) - User-Agent header for USCIS WAF compatibility
…y mappings - Covers FAANG, major tech, H-1B consultancies, finance/banking sectors - Maps common brand names to exact USCIS legal entity names - Includes custom aliases section for user additions
- SUMMARY.md with task results, verification, self-check
- File-based JSON cache in data/visa/cache/ with configurable TTL - Cache keys: source-sanitized-hash pattern (case-insensitive, filesystem-safe) - Default TTLs: USCIS=90d, E-Verify=7d, Salary=30d - CLI interface: stats, clear, get commands - Negative result caching (found:false) supported - T-02-06/T-02-07 mitigations: JSON validation, path sanitization - 8 behavior tests in test-visa-cache.mjs (all passing)
- Commented template with visa_status and sponsorship_mode fields - Documents 3 sponsorship modes: hard_filter, score_penalty, info_only - Optional cache_ttl overrides section (commented out) - Placeholder OPT section for Phase 4 (commented out) - Feature toggle pattern: file existence activates visa features
- SUMMARY.md with task commits, threat mitigations, self-check
…ontract - Add gitignore entries for data/visa/uscis/, data/visa/cache/, config/visa.yml with sample/ negation - Add config/visa.yml and data/visa/ to USER_PATHS in update-system.mjs - Add config/visa.example.yml and config/employer-aliases.yml to SYSTEM_PATHS - Document visa files in correct layer tables in DATA_CONTRACT.md
- Add checkVisaData() with 3 checks: USCIS data, cache dir, employer aliases - Gate all visa checks behind config/visa.yml existence (silent skip when absent) - Integrate visa checks into main() after existing checks, before summary
…ng updates The comment in employer-aliases.yml incorrectly stated custom mappings survive system updates. Since this file is in SYSTEM_PATHS, it gets overwritten on update. Updated comment to warn users and direct them to config/employer-aliases.local.yml for custom aliases. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…in test Match production visa-cache.mjs error handling: wrap unlinkSync in try/catch so locked or read-only files on Windows don't crash the test suite with an unhandled exception. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Git porcelain format outputs renamed files as "R old -> new". The previous slice(3) captured the entire string as the path, which could cause false matches against USER_PATHS during update safety validation. Now extracts only the new path for renames. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
4 plans across 3 waves: keyword detection (01), H-1B lookup (02), composite scoring (03), and mode integration (04). Covers all 14 phase requirements (SPNS-01-08, H1B-02-03, VSCO-01-04). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Add config/sponsorship-keywords.yml with 4 keyword categories (positive, negative, government, authorization) - Add sponsorship-detect.mjs CLI tool classifying JD text into WILL_SPONSOR/WONT_SPONSOR/UNKNOWN - Support --test, --file, --stdin, --json modes - All 8 built-in tests pass including case-insensitive and conflicting signal handling
- Add config/sponsorship-keywords.yml and sponsorship-detect.mjs to SYSTEM_PATHS - Add section 10 (Sponsorship detection) to test-all.mjs running --test self-check - Full test suite passes (62 passed, 0 failed)
- USCIS CSV querying with alias resolution and normalized matching - Petition counts, approval rates, and YoY trend analysis - 90-day TTL caching via duplicated visa-cache functions - CLI with --json, --sample, --no-cache, --test modes - 17 built-in tests passing against sample CSV data
- Section 10: runs h1b-lookup.mjs --test as part of full test suite - Graceful skip if h1b-lookup.mjs not present
- 2/2 tasks completed, all verification passing - h1b-lookup.mjs with alias resolution, trend analysis, caching - Integrated into test-all.mjs test suite
- Weighted 5-component scoring: JD signals (30%), H-1B history (30%), E-Verify (20%), company size (10%), STEM job (10%) - Three sponsorship modes: hard_filter (SKIP), score_penalty (-0.7/-0.3), info_only (no impact) - Missing components default to neutral 3/5 - Zero-filing large companies scored lower than small companies - 15 built-in tests all passing
- Added section 12 for visa-score.mjs --test integration - Follows existing pattern of sponsorship-detect and h1b-lookup sections
…n to _shared.md - Add hard_filter pre-check before Block A in oferta.md (WONT_SPONSOR = immediate SKIP) - Insert new Block G Visa Sponsorship Analysis with table format and script references - Rename existing Block G (Draft Application Answers) to Block H - Add Visa-Friendliness dimension to _shared.md scoring framework with 3 mode descriptions
…te data contract - Add Paso 1.5 visa pre-filter to batch-prompt.md (hard_filter WONT_SPONSOR = SKIP) - Add Block G Visa Sponsorship Analysis to batch evaluation pipeline - Add visa_score and visa_classification to batch JSON output (success + failed) - Add sponsorship indicator column to scan.md ([SPONSOR]/[NO-SPNS]/[?]) without filtering - Register config/sponsorship-keywords.yml in DATA_CONTRACT.md system layer
…arser
- The keyMatch regex failed on Windows due to \r in line endings after split('\n')
- Strip trailing \r before matching category key lines
- Deviation Rule 3: blocking issue preventing test verification
Accept upstream's Block G (Posting Legitimacy) over local visa module changes. Visa module work preserved on feat/visa-module branch. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Two plans covering OPT-01 through OPT-07: Plan 01 builds opt-timeline.mjs core script and config/visa.example.yml; Plan 02 wires into evaluation modes, creates visa-status command, registers tests, updates docs. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- opt-timeline.mjs: 856-line standalone script with OPT expiration, unemployment tracking (90/150 day limits), H-1B cap season detection (5 phases with year-wrap), and time-to-hire estimation from JD text - config/visa.example.yml: template with opt:, time_to_hire_defaults:, and sponsorship settings sections - Supports --test (62 inline tests), --json (pipeline integration), and human-readable dashboard modes Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- modes/oferta.md: OPT status banner in Block G with 3-tier warning escalation (60/30/14 day thresholds) - modes/visa-status.md: new standalone OPT dashboard command - modes/scan.md: one-line OPT notice at scan output top - batch/batch-prompt.md: OPT banner + optStatus in JSON output schema - test-all.mjs: fix duplicate section numbering, add section 14 for opt-timeline tests - .claude/skills/career-ops/SKILL.md: register visa-status route - docs/VISA.md: full OPT timeline documentation Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- CR-01: Add UNSAFE_KEYS guard to prevent prototype pollution - WR-01: Use matched-pair quote stripping (no mismatched strip) - WR-02: Only strip inline comments on unquoted YAML values - WR-03: Add zero-month guard in calculateExpiration Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
opt-timeline.mjs- standalone OPT timeline calculator with 62 inline testscovering expiration (regular 12mo / STEM 36mo), unemployment tracking (90/150 day
limits), H-1B cap season detection (5 phases with year-wrap), and time-to-hire
estimation from JD text
config/visa.example.yml- visa config template withopt:,time_to_hire_defaults:, and sponsorship settingsmodes/visa-status.md- new/career-ops visa-statuscommand for quick OPTdashboard
modes/oferta.md(Block G),batch/batch-prompt.md, andmodes/scan.mdwith 3-tier warning escalation (60/30/14 days)test-all.mjs, add section 14 for opt-timelinetests
visa-statusroute inSKILL.mddocs/VISA.mdwith full OPT module documentationTest plan
node opt-timeline.mjs --test— 62 tests passnode test-all.mjs— section 14 (OPT timeline) passesecho '{"optConfig":{"type":"stem","start_date":"2025-06-01","unemployment_days_u sed":45},"jdText":"Fortune 500"}' | node opt-timeline.mjs --json— returns structuredJSON
config/visa.example.yml→config/visa.yml, runnode opt-timeline.mjs—dashboard output
modes/oferta.mdBlock G contains OPT banner instructions.claude/skills/career-ops/SKILL.mdrouting table includesvisa-status