惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

罗磊的独立博客
L
LangChain Blog
aimingoo的专栏
aimingoo的专栏
IT之家
IT之家
B
Blog
博客园_首页
博客园 - 司徒正美
有赞技术团队
有赞技术团队
博客园 - 聂微东
I
InfoQ
美团技术团队
GbyAI
GbyAI
阮一峰的网络日志
阮一峰的网络日志
H
Help Net Security
大猫的无限游戏
大猫的无限游戏
MyScale Blog
MyScale Blog
WordPress大学
WordPress大学
The GitHub Blog
The GitHub Blog
A
About on SuperTechFans
人人都是产品经理
人人都是产品经理
Microsoft Azure Blog
Microsoft Azure Blog
Engineering at Meta
Engineering at Meta
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
The Cloudflare Blog

Hacker News - Newest: "AI"

AI can't read an investor deck AI as an attorney? Student uses ChatGPT, Gemini to sue UW over alleged racial discrimination Hacking MCP Servers in AI Systems – The Rug Pull: Tool Changes After Approval GitHub - MeepCastana/KubeezCut: Free Web based video editor Can AI judge journalism? A Thiel-backed startup says yes, even if it risks chilling whistleblowers Coming soon: 10 Things That Matter in AI Right Now DARPA built an AI to fact-check enemy weapons claims What explains heterogeneity in AI adoption? When AI Meets Muscle: Context-Aware Electrical Stimulation Promises a New Way to Guide Human Movements - Department of Computer Science AI Changed How We Build. It Did Not Change What Matters. Linux rules on using AI-generated code - Copilot is OK, but humans must take 'full responsibility for the… Meta spins up AI version of Mark Zuckerberg to engage with employees Code Mode: Let Your AI Write Programs, Not Just Call Tools | TanStack Blog GitHub - Delavalom/graft: Go framework for building AI agents. Type-safe tools, multi-provider (OpenAI, Anthropic, Gemini, Bedrock), zero vendor SDKs. India's TCS tops estimates, says new AI models did not dent services demand Gen Z's fading AI hype Strong feeling: we are in a folded AI reality GitHub - machinarii/total-recall-catalog: A reference catalog of latest knowledge retrieval, memory & RAG systems GitHub - mensfeld/code-on-incus: Give each AI agent its own isolated machine with root, Docker, and systemd. Active defense detects and stops threats automatically.. Quantization, LoRA, and the 8% Problem: Benchmarking Local LLMs for Production AI Iran war: We spoke to the man making Lego-style AI videos that experts say are powerful propaganda Powell, Bessent discussed Anthropic's Mythos AI cyber threat with major U.S. banks GitHub - immartian/bellamem: Persistent belief-graph memory for AI agents. Retrieves decisive context by importance — not recency, not RAG, not /compact. recursive-mode: The Repo-Native Operating System for AI Engineering After the attack on Sam Altman's home, will AI CEO's go on the offensive? The biggest advance in AI since the LLM Opus 4.6 vs GPT 5.4 One Prompt Unity World Generation Test “AI polls” are fake polls Client Challenge Can AI be a 'child of God'? Inside Anthropic's meeting with Christian leaders
GitHub - alitariq4589/ci-medic: AI triage for failed CI r...
alitariq4589 · 2026-06-26 · via Hacker News - Newest: "AI"

AI triage for failed CI runs. When your pipeline goes red, ci-medic reads the logs, finds the real error in the noise, and posts an AI-based verdict — code, flake, infra, dependency, or config — right where you already look.

Secrets are redacted before any model sees them. Point it at a local model and your logs never leave your network.

Not a button you click to "explain this error". ci-medic runs automatically on failure, distills thousands of noisy log lines to the real error, redacts secrets, and posts a structured verdict on CI systems where single hosted AI assistant doesn't reach.

Supported CI platforms

  • GitHub Actions: sticky editable PR comment, zero setup
  • Jenkins: build description (requires one-time setup on your agent; native plugin on the roadmap)
  • GitLab CI: planned
  • Bitbucket Pipelines: planned

Any other CI can use the CLI against a log file today.


Installation

GitHub Actions

Add a triage job that runs only on failure:

# .github/workflows/ci.yml
  triage:
    if: failure()
    needs: [build, test]          # the jobs to triage
    runs-on: ubuntu-latest
    permissions:
      actions: read               # read failed job logs
      pull-requests: write        # post the comment
    steps:
      - uses: alitariq4589/ci-medic@v0.1.0
        with:
          github-token: ${{ secrets.GITHUB_TOKEN }} 
          api-key: ${{ secrets.CI_MEDIC_API_KEY }}   # optional (see Model providers)

github-token uses the built-in token in the pipeline automatically. Without api-key, ci-medic still posts the extracted error window, just without the AI verdict. The comment is sticky and re-runs update it in place.

Full walkthrough with screenshots: docs/github-actions.md

Jenkins

Jenkins has no marketplace that provisions tools into pipelines, so setup has two roles: an admin makes ci-medic available on the agent once, then pipeline authors add a small block. (A native Jenkins plugin that removes the admin step is on the roadmap.)

1. Admin setup: make ci-medic available on your agent (one-time). Any one of:

  • Install it on the agent environment: pip install git+https://github.com/alitariq4589/ci-medic
  • Or, if you run Docker-based agents, add it to your agent image.

Provide the model key to the agent as the CI_MEDIC_API_KEY environment variable (or a Jenkins credential injected into the stage).

2. Pipeline author setup: add the triage block. Tee build output to a file, then triage it on failure:

post {
  failure {
    script {
      def verdict = sh(
        script: 'ci-medic jenkins --file ci-medic-console.log --job "$JOB_NAME"',
        returnStdout: true
      ).trim()
      currentBuild.description = verdict
    }
  }
}

where your build stage writes the log:

sh '''#!/bin/bash
  set -o pipefail
  { ./your-build-and-test; } 2>&1 | tee ci-medic-console.log
'''

set -o pipefail keeps the stage failing on error (so the failure block fires); the verdict lands at the top of the build page. No Jenkins API token and no script-approval needed because ci-medic only reads a file.

→ Full walkthrough with screenshots: docs/jenkins.md

CLI / local use

Run ci-medic on any log file (no CI integration required):

pip install git+https://github.com/alitariq4589/ci-medic

# Distill only: No key, nothing leaves your machine:
ci-medic analyze --file failed.log --no-llm

# Full AI-based triage:
export CI_MEDIC_API_KEY="your-key" # can be openrouter, anthropic, openai API token
ci-medic analyze --file failed.log

Model providers

ci-medic works with any OpenAI-compatible API or the Anthropic API. Set the provider via environment variables or .ci-medic.yml:

  • OpenRouter: one key, many models (this is default as it includes free models too. The default openrouter selected models are in src/ci_medic/config.py) - Tested
  • OpenAI - Untested
  • Anthropic - Untested
  • Ollama: local, zero egress - Untested
  • llama.cpp (llama-server): local, zero egress - Untested
  • Any other OpenAI-compatible endpoint
export CI_MEDIC_API_KEY="your-key"
export CI_MEDIC_BASE_URL="https://openrouter.ai/api/v1"   # provider endpoint
export CI_MEDIC_MODEL="your-model"                         # provider's model id

You choose the model; ci-medic doesn't lock you to one. With no model specified, it tries a priority chain and falls through on rate-limit or no-credit, recording which it used.


Private mode (local model)

ci-medic's code is open source (Apache-2.0) — on GitHub you reference the public action, and you're free to fork or vendor it. What "private" controls is your data: where your logs go.

Point ci-medic at a local model server and no log content ever leaves your network:

export CI_MEDIC_BASE_URL="http://localhost:11434/v1"   # Ollama (or llama.cpp's llama-server)
export CI_MEDIC_MODEL="your-local-model"
# set no cloud key

The distillation and secret-redaction steps always run locally regardless of provider; only the distilled, redacted window is ever sent to a model, and with a local model, even that stays on your machine.


Privacy & security

Before any model call, ci-medic redacts known secret formats and runs an entropy filter for high-randomness strings in unknown formats. (See docs/redaction.md for the exact patterns covered.) For zero egress, use a local model and set no cloud key.


Advanced configuration

Optional .ci-medic.yml in your repo root (see examples/.ci-medic.yml):

provider: openai-compat                       # or: anthropic
base_url: https://openrouter.ai/api/v1
char_budget: 12000
ignore_jobs: ["lint", "codeql"]               # skip these jobs
extra_signals: ["MY_CUSTOM_ERROR_TOKEN"]      # extra strings to treat as errors

Environment variables override the file.


Roadmap

  • GitHub Actions and Jenkins (CLI-based) ship in v0.1.

  • Jenkins plugin (install from the Update Center, no agent setup),

  • GitLab CI

  • flaky-test memory that tracks chronic flakes across runs

  • hardware/LAVA log triage.

License

Apache-2.0