python-azure-iot-edge-modules
它能做什么
这个工具可以帮你构建和管理在联网设备(IoT Edge)上运行的 Python 程序(模块)。它能确保这些程序运行稳定、正确发送数据,而且便于更新。
适用场景
- ✓在设备上创建一个处理传感器数据的程序。
- ✓将数据从设备可靠地发送到云端。
- ✓把设备数据转换成云端能够理解的格式。
技能链接
https://github.com/github/awesome-copilot/blob/main/skills/python-azure-iot-edge-modules/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“帮我创建一个 Python 模块,从传感器采集温度数据,并把数据发送到云端。”
每周 5 个新技能,1 分钟读完。
工作原理
这个工具会依据 Python 最佳实践和 Microsoft Azure 的指南来构建模块。它会定义模块如何通信、如何处理网络故障,以及如何部署到设备上。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
Python Azure IoT Edge Modules
Use this skill to design, implement, and validate Python-based IoT Edge modules for telemetry processing, local inference, protocol translation, and edge-to-cloud integration.
When To Use
Use this skill for requests like:
- "quiero crear un modulo Python para IoT Edge"
- "como despliego modulos edge con manifest"
- "necesito filtrar/agregar telemetria antes de subirla"
- "como manejo desconexiones y reintentos en edge"
Mandatory Docs Review
Before recommending runtime behavior or deployment decisions, review:
Minimum checks:
- Runtime architecture and module lifecycle.
- Supported host OS and versions.
- Deployment model and configuration flow.
- Current release/version guidance.
If documentation cannot be fetched, proceed with explicit assumptions and flag them clearly.
Python Official References and Best Practices (Required)
Before proposing Python implementation details, consult official Python sources:
- https://www.python.org/
- https://docs.python.org/3/
- https://docs.python.org/3/reference/
- https://docs.python.org/3/library/
- references/python-official-best-practices.md
Prefer official docs over community snippets unless there is a specific compatibility reason to deviate.
Goals
- Deliver module architecture and implementation plan that is production-focused.
- Ensure reliable edge messaging under network variability.
- Provide deployment, observability, and validation artifacts.
Module Use Cases
- Protocol adapter (serial/Modbus/OPC-UA to IoT message format).
- Telemetry enrichment and normalization.
- Local anomaly detection or inference.
- Command orchestration and local actuator control.
Delivery Workflow
1) Contract and Interfaces
Define:
- Module inputs and outputs.
- Message schema and versioning policy.
- Routes and priorities for normal vs critical telemetry.
- Desired properties used for dynamic configuration.
2) Runtime and Packaging
Specify:
- Python runtime version target.
- Container image strategy (base image, slim footprint, CVE hygiene).
- Resource profile (CPU/memory bounds).
- Startup and health checks.
3) Reliability Design
Implement and validate:
- Retries with exponential backoff and jitter.
- Graceful degradation on upstream failures.
- Local queueing strategy where needed.
- Idempotent processing for replayed messages.
4) Security Controls
Require:
- No plaintext secrets in code or manifest.
- Least-privilege module behavior.
- Secure transport and trusted cert chain handling.
- Traceability for command handling and state changes.
5) Deployment and Operations
Define:
- Environment-specific deployment manifests.
- Rollout strategy (pilot, staged, broad).
- Rollback criteria.
- SLOs and alerting conditions.
Reuse Other Skills
When relevant, combine with:
azure-smart-city-iot-solution-builderfor platform-level architecture.appinsights-instrumentationfor telemetry instrumentation approaches.azure-resource-visualizerfor architecture diagrams and dependency mapping.
Also use references/python-official-best-practices.md as baseline quality criteria for module design and implementation guidance.
Required Output
Always provide:
- Module design brief (purpose, inputs, outputs).
- Deployment model (image, manifest, env settings).
- Reliability and error-handling strategy.
- Security and operations checklist.
- Test matrix (functional, chaos, performance, rollback).
Output Template
Use references/python-edge-module-template.md to structure implementation proposals and reviews.
- Context and assumptions
- Module architecture
- Deployment and configuration
- Reliability, security, observability
- Validation and rollout plan
Guardrails
- Do not recommend direct production rollout without pilot stage.
- Do not embed secrets in Dockerfiles, source, or manifests.
- Do not omit health probes, restart behavior, and rollback criteria.
常见问题
什么是 IoT Edge?
它是微软推出的一个平台,可以让你直接在边缘设备上运行 AI 和其他 Azure 服务,而不必全部放到云端。
IoT Edge 中的模块是什么?
模块是在 IoT Edge 上运行的软件组件。它们可以是自定义应用(比如用 Python 编写的应用),也可以是 Azure 服务。
为什么要在 IoT Edge 上使用 Python?
Python 是一种流行且通用的语言,拥有大量用于数据处理、机器学习和通信的实用库,因此非常适合用来构建 IoT Edge 模块。
详情
作者的原始描述
Build and operate Python Azure IoT Edge modules with robust messaging, deployment manifests, observability, and production readiness checks.
repo: github/awesome-copilot
热度
- GitHub 星标
- 40k
- 排名
- #7350
- 许可证
- MIT
- 更新时间
- 2026/10/15
评论
- …
同一仓库的更多技能
acquire-codebase-knowledge
40k帮你的智能体理解并编写现有代码项目的文档。它有助于新成员快速上手,或者快速了解项目架构。
acreadiness-assess
40k让你的智能体评估一个项目对 AI 的准备程度,并生成报告。它有助于了解项目在使用 AI 工具方面的准备情况。
acreadiness-generate-instructions
40k帮你的智能体根据评估结果编写 AI 工具的指令文件。它有助于改善 AI 与代码的交互方式,并弥补已发现的不足。
acreadiness-policy
40k让你的智能体协助制定或应用 AI 项目评估的政策。它有助于规范项目的评估方式,并确保合规。