{
  "contentStorage": "postgres",
  "title": "Code Llama",
  "description": "Code Llama 是 Meta 于 2023 年 8 月 24 日发布的代码特化大模型，是 Llama 2 的代码衍生系列。",
  "url": "/ko/works/code-llama/at/1.html",
  "entity": {
    "id": "work_code_llama",
    "type": "work",
    "title": "Code Llama",
    "slug": "code-llama",
    "summary": "Code Llama 是 Meta 于 2023 年 8 月 24 日发布的代码特化大模型，是 Llama 2 的代码衍生系列。",
    "status": "published",
    "categories": [
      "category-science-technology"
    ],
    "tags": [],
    "sources": [
      {
        "id": "s1",
        "title": "Introducing Code Llama, a state-of-the-art large language model for coding — Meta AI",
        "url": "https://ai.meta.com/blog/code-llama-large-language-model-coding/"
      },
      {
        "id": "s2",
        "title": "Introducing Code Llama, an AI Tool for Coding — Meta",
        "url": "https://about.fb.com/news/2023/08/code-llama-ai-for-coding/"
      },
      {
        "id": "s3",
        "title": "Code Llama: Open Foundation Models for Code — arXiv:2308.12950",
        "url": "https://arxiv.org/pdf/2308.12950"
      },
      {
        "id": "s4",
        "title": "Code Llama — Hugging Face",
        "url": "https://huggingface.co/codellama"
      }
    ],
    "createdAt": "2026-11-10T15:05:22+08:00",
    "updatedAt": "2026-11-10T15:05:22+08:00",
    "updatedBy": "user:admin",
    "revision": 1,
    "body": "Code Llama 是 Meta 于 2023 年 8 月 24 日发布的代码特化大模型，是 Llama 2 的代码衍生系列。[^s1]\n\n## 发布背景\n发布时上下文窗口为100K tokens。[^s1]\nMeta 官方定性为 Llama 2 的代码特化版本，由 Llama 2 在代码数据集上继续训练而成，但有独立博客、论文、模型卡与 GitHub 仓库[^s1]\n\n## 定价与获取\n开源权重，沿用 Llama 2 社区许可，可免费用于研究与商业用途；训练序列为 16K tokens，官方称在最长 100K tokens 输入上仍有改进，7B/13B 基础版与 Instruct 版支持代码填空。[^s1]\n\n## 性能表现\n以下为Meta公布的自家评测结果，尚未经独立复现。[^s1]\n- HumanEval：53.7% pass@1（Code Llama 34B）（高于 Llama 2，与 GPT-3.5（48.1%）相当）[^s1]\n- MBPP：56.2% pass@1（Code Llama 34B）（为当时公开模型中最高之一）[^s1]\n- HumanEval：67.8% pass@1（Code Llama 70B-Instruct）（略高于 GPT-4 的 67.0%）[^s1]\n- MBPP：65.6% pass@1（Code Llama 70B-Python）（为该系列最高 MBPP 分数）[^s1]\n\n## 主要特点\n- 版本线为 7B/13B/34B（2023-08-24）及 70B（2024-01-29），每尺寸分基础版、Code Llama - Python 与 Code Llama - Instruct 三种变体[^s1]\n\n## 定位与后续\nLlama 2 的代码特化衍生系列，定位为开源代码生成与补全模型，后继为 Llama 3 及后续世代内置的更强代码能力，无独立的 Code Llama 3 续作。 其基础模型为[[work_llama_2|Llama 2]]。[^s1]",
    "url": "/works/code-llama.html",
    "lang": "ko",
    "sourceLang": "zh",
    "fallback": true,
    "availableLangs": [
      "zh"
    ],
    "workKind": "ai_model"
  },
  "entities": null,
  "relations": [
    {
      "id": "relation_work_code_llama_published_by_meta",
      "fromId": "work_code_llama",
      "relationType": "published_by",
      "toId": "organization_meta",
      "sourceRefs": [
        {
          "entityId": "work_code_llama",
          "sourceId": "s1"
        }
      ],
      "label": "Published by",
      "targetId": "organization_meta",
      "targetTitle": "Meta",
      "targetUrl": "/ko/organizations/meta.html",
      "incoming": false
    }
  ],
  "versions": [
    {
      "revision": 1,
      "updatedAt": "2026-11-10T15:05:22+08:00",
      "message": "当前版本",
      "hasSnapshot": true,
      "url": "/ko/works/code-llama/at/1.html"
    }
  ],
  "viewRevision": 1,
  "lang": "ko",
  "availableLangs": [
    "zh"
  ],
  "fallback": true,
  "infoFields": [
    {
      "key": "work_kind",
      "label": "Work kind",
      "value": "인공지능 모델"
    }
  ],
  "relationsTotal": 1,
  "relationCounts": [
    {
      "relationType": "published_by",
      "incoming": false,
      "label": "Published by",
      "total": 1
    }
  ]
}