| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596 |
- #!/usr/bin/env bash
- set -euo pipefail
- BASE_URL="${BASE_URL:-http://localhost:8080}"
- ENDPOINT="${BASE_URL%/}/api/exam-sprint/outlook-reports"
- RESPONSE_BODY="$(mktemp)"
- cleanup() {
- rm -f "$RESPONSE_BODY"
- }
- trap cleanup EXIT
- http_code="$({
- curl -sS \
- -o "$RESPONSE_BODY" \
- -w '%{http_code}' \
- -X POST \
- -H 'Content-Type: application/json' \
- --data-binary @- \
- "$ENDPOINT" <<'JSON'
- {
- "reportMetadata": {
- "reportVersionLabel": "2026 词汇展望报告",
- "learnerName": "李同学",
- "targetExamName": "雅思 6.5",
- "sprintPeriodLabel": "2026 春季冲刺",
- "authorName": "Ability Bot"
- },
- "readinessOverview": {
- "summary": "词汇能力进入提分窗口,适合围绕考纲和高频场景做集中突破。",
- "currentStage": "当前阶段:稳态提升",
- "keyInsight": "核心观察:阅读词汇优于写作输出,仍需补齐同义替换。",
- "readinessScore": 78
- },
- "syllabusMasteryChart": {
- "totalWordCount": 4200,
- "masteredWordCount": 3192,
- "unmasteredWordCount": 1008,
- "masteryPercent": 76,
- "summaryLabel": "考纲词汇掌握概览",
- "recommendation": "先补齐教育、科技和环境主题词,再做套题复盘。"
- },
- "pastPaperVocabularyChart": {
- "totalWordCount": 800,
- "unknownWordCountBeforeSprint": 180,
- "unknownWordCountAfterSprint": 120,
- "projectedScoreGainLabel": "预计提分 5-10 分",
- "recommendation": "每次精听后补 5 组同义替换并做口头复述。"
- },
- "highFrequencyVocabularyChart": {
- "basicCorePercent": 77,
- "highScorePercent": 62,
- "highlightLabel": "Common 高频词覆盖较广,但易混词记忆不牢。"
- },
- "vocabularyFrequencyBandChart": {
- "bars": [
- {"bandLabel": "2k 高频", "currentValue": 86, "priorityLabel": "优先学习", "themeColor": "#448aff"},
- {"bandLabel": "3k 高频", "currentValue": 78, "priorityLabel": "重点突破", "themeColor": "#4caf50"},
- {"bandLabel": "学术词", "currentValue": 62, "priorityLabel": "酌情学习", "themeColor": "#ff9800"}
- ]
- },
- "frequencyPlan": {
- "cards": [
- {"cadencePerWeek": 3, "scoreGainLabel": "+12 分", "winRatePercent": 78, "recommended": true, "badgeLabel": "推荐", "emphasisIcon": "③"},
- {"cadencePerWeek": 2, "scoreGainLabel": "+8 分", "winRatePercent": 61, "recommended": false, "badgeLabel": "稳妥", "emphasisIcon": "②"}
- ],
- "recommendationTitle": "💡建议策略",
- "recommendationSummary": "7 天提分冲刺优先保证高频词正确率,再逐步覆盖中频词。",
- "phaseSuggestions": [
- {"title": "考前半个月·核心突击期", "description": "围绕高频词建立记忆闭环。"},
- {"title": "考前一周·强化巩固期", "description": "结合真题错词做循环复盘。"}
- ]
- },
- "scoreImprovementCaseStudy": {
- "headline": "教育类阅读题案例",
- "learnerName": "李同学",
- "studyPeriodLabel": "考前半个月·核心突击期",
- "memorizedWordCount": 705,
- "examHitWordCount": 237,
- "hitRatePercent": 33.6,
- "baselineScoreLabel": "70 分以下",
- "finalScore": 89,
- "scoreGain": 19
- }
- }
- JSON
- })"
- printf 'HTTP %s\n' "$http_code"
- cat "$RESPONSE_BODY"
- if [ "$http_code" != "202" ]; then
- exit 1
- fi
|