mirror of
https://github.com/crewAIInc/crewAI.git
synced 2026-07-01 05:08:12 +00:00
* feat: adopt directory-based docs versioning with Edge channel Switch docs.crewai.com from navigation-only versioning (every version selector entry rendered the same docs/<lang>/* source files) to Mintlify's directory-based versioning so each version selector entry renders its own snapshot. Add an "Edge" channel under docs/edge/<lang>/* that always reflects main HEAD for unreleased work, eliminating pre-release leakage onto frozen release labels. External links to canonical /<lang>/* URLs are preserved via wildcard redirects that always land on the current default version. Layout: - docs/edge/<lang>/* rolling source (you edit here) - docs/edge/enterprise-api.*.yaml - docs/v<X.Y.Z>/<lang>/* frozen, immutable snapshots - docs/v<X.Y.Z>/enterprise-api.*.yaml - docs/images/ shared, append-only - docs/docs.json nav + redirects URLs follow the Mintlify-idiomatic shape: /edge/<lang>/<page> for Edge, /v<X.Y.Z>/<lang>/<page> for every frozen snapshot. The wildcard redirects /<lang>/:slug* -> /<default>/<lang>/:slug* keep stale links working, and every freeze rewrites them (plus all per-section/per-page redirects) so destinations always resolve to the current default without depending on a second redirect hop. Release flow integration (devtools release): - New module crewai_devtools.docs_versioning.freeze() materialises docs/v<X.Y.Z>/ from docs/edge/, rewrites openapi: refs inside the snapshot, inserts the version into every language block in docs.json, and refreshes all redirect destinations. - _update_docs_and_create_pr() in cli.py now calls that freeze during Phase 2 of devtools release. Edge changelogs are updated first (so the snapshot freeze picks them up), then the snapshot is staged alongside docs.json, branched as docs/freeze-v<X.Y.Z>, and the PR is titled [docs-freeze] docs: snapshot and changelog for v<X.Y.Z> — the title prefix the new CI guard reads. - The PR still gates tag, GitHub release, PyPI publish, and the enterprise release as before; no new PRs are added. - Pre-releases (1.X.YaN, 1.X.YbN, ...) skip the snapshot — they ride Edge — and the docs PR title omits the [docs-freeze] prefix. - docs_check (AI-generated docs scaffolding) writes to docs/edge/<lang>/* so newly-generated unreleased docs land in Edge and never accidentally touch a frozen snapshot. Migration scripts (one-shot): - scripts/docs/freeze_historical_versions.py reconstructs all 16 historical snapshots (v1.10.0 .. v1.14.7) from git tags via git archive | tar, rewriting openapi: MDX refs so each snapshot reads its own enterprise-api YAML rather than the live one. - scripts/docs/prefix_version_paths.py one-shot-migrates docs.json: rewrites every page path in 16 versioned blocks to point under docs/v<X.Y.Z>/, inserts a new Edge entry per language, tags v1.14.7 as Latest (default), prunes pages whose target file doesn't exist in the snapshot (e.g. docs/ar/ didn't exist before v1.12.0), and writes the wildcard + per-section redirects. - scripts/docs/freeze_current_edge.py is now a thin CLI wrapper around docs_versioning.freeze for manual one-off freezes (e.g. retroactively snapshotting a forgotten release). CI guards (.github/workflows/docs-snapshots.yml): - Frozen snapshots under docs/v[0-9]*/ are immutable; only PRs whose title contains [docs-freeze] (i.e. release-cut PRs generated by devtools release or the manual wrapper) may modify them. - Images under docs/images/ are append-only since snapshots share a single image directory. Deleting or renaming an image breaks every historical snapshot that still references it. Restored docs/images/crewai-otel-export.png from PR #3673; it was deleted in PR #4908 but v1.10.0 / v1.10.1 snapshots still reference it. Restoring instead of editing the snapshots preserves historical rendering fidelity and validates the new append-only rule retroactively. Tests: - lib/devtools/tests/test_docs_versioning.py covers the freeze: file copy, openapi rewrite, version insertion, default demotion, redirect upserts, per-section redirect rewriting, idempotency, and invalid inputs. Verified locally with mintlify broken-links: 0 broken links across the full site (Edge + 16 frozen versions, 4 locales). AGENTS.md (repo root) is the contributor guide for the new model; RELEASING.md is the release-cut runbook; README's Contribution section links to both. Co-authored-by: Cursor <cursoragent@cursor.com> * style: resolve linter issues --------- Co-authored-by: Cursor <cursoragent@cursor.com>
217 lines
8.2 KiB
Plaintext
217 lines
8.2 KiB
Plaintext
---
|
|
title: التثبيت
|
|
description: ابدأ مع CrewAI - التثبيت والتهيئة وبناء أول فريق AI
|
|
icon: wrench
|
|
mode: "wide"
|
|
---
|
|
|
|
### شاهد: بناء Agents و Flows في CrewAI باستخدام Coding Agent Skills
|
|
|
|
قم بتثبيت مهارات وكيل البرمجة الخاصة بنا (Claude Code، Codex، ...) لتشغيل وكلاء البرمجة بسرعة مع CrewAI.
|
|
|
|
يمكنك تثبيتها باستخدام `npx skills add crewaiinc/skills`
|
|
|
|
<iframe src="https://www.loom.com/embed/befb9f68b81f42ad8112bfdd95a780af" frameborder="0" webkitallowfullscreen mozallowfullscreen allowfullscreen style={{width: "100%", height: "400px"}}></iframe>
|
|
|
|
## فيديو تعليمي
|
|
|
|
شاهد هذا الفيديو التعليمي لعرض تفصيلي لعملية التثبيت:
|
|
|
|
<iframe
|
|
className="w-full aspect-video rounded-xl"
|
|
src="https://www.youtube.com/embed/-kSOTtYzgEw"
|
|
title="CrewAI Installation Guide"
|
|
frameBorder="0"
|
|
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture"
|
|
allowFullScreen
|
|
></iframe>
|
|
|
|
## دليل نصي
|
|
|
|
<Note>
|
|
**متطلبات إصدار Python**
|
|
|
|
يتطلب CrewAI إصدار `Python >=3.10 and <3.14`. إليك كيفية التحقق من إصدارك:
|
|
|
|
```bash
|
|
python3 --version
|
|
```
|
|
|
|
إذا كنت بحاجة لتحديث Python، قم بزيارة [python.org/downloads](https://python.org/downloads)
|
|
|
|
</Note>
|
|
|
|
<Note>
|
|
**متطلبات OpenAI SDK**
|
|
|
|
يتطلب CrewAI 0.175.0 إصدار `openai >= 1.13.3`. إذا كنت تدير التبعيات بنفسك، تأكد من أن بيئتك تستوفي هذا الشرط لتجنب مشاكل الاستيراد/التشغيل.
|
|
|
|
</Note>
|
|
|
|
يستخدم CrewAI أداة `uv` لإدارة التبعيات والحزم. وهي تبسّط إعداد المشروع وتنفيذه وتوفر تجربة سلسة.
|
|
|
|
إذا لم تكن قد ثبّتت `uv` بعد، اتبع **الخطوة 1** لإعدادها بسرعة على نظامك، وإلا يمكنك الانتقال إلى **الخطوة 2**.
|
|
|
|
<Steps>
|
|
<Step title="تثبيت uv">
|
|
- **على macOS/Linux:**
|
|
|
|
استخدم `curl` لتحميل السكريبت وتنفيذه عبر `sh`:
|
|
|
|
```shell
|
|
curl -LsSf https://astral.sh/uv/install.sh | sh
|
|
```
|
|
إذا لم يكن `curl` متاحًا على نظامك، يمكنك استخدام `wget`:
|
|
|
|
```shell
|
|
wget -qO- https://astral.sh/uv/install.sh | sh
|
|
```
|
|
|
|
- **على Windows:**
|
|
|
|
استخدم `irm` لتحميل السكريبت و`iex` لتنفيذه:
|
|
|
|
```shell
|
|
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
|
|
```
|
|
إذا واجهت أي مشاكل، راجع [دليل تثبيت UV](https://docs.astral.sh/uv/getting-started/installation/) لمزيد من المعلومات.
|
|
</Step>
|
|
|
|
<Step title="تثبيت CrewAI">
|
|
- شغّل الأمر التالي لتثبيت واجهة سطر أوامر `crewai`:
|
|
```shell
|
|
uv tool install crewai
|
|
```
|
|
<Warning>
|
|
إذا ظهر تحذير بشأن `PATH`، شغّل هذا الأمر لتحديث الصدفة:
|
|
```shell
|
|
uv tool update-shell
|
|
```
|
|
</Warning>
|
|
|
|
<Warning>
|
|
إذا واجهت خطأ بناء `chroma-hnswlib==0.7.6` (`fatal error C1083: Cannot open include file: 'float.h'`) على Windows، ثبّت [Visual Studio Build Tools](https://visualstudio.microsoft.com/downloads/) مع خيار *Desktop development with C++*.
|
|
</Warning>
|
|
|
|
- للتحقق من تثبيت `crewai`، شغّل:
|
|
```shell
|
|
uv tool list
|
|
```
|
|
- يجب أن ترى شيئًا مثل:
|
|
```shell
|
|
crewai v0.102.0
|
|
- crewai
|
|
```
|
|
- إذا كنت بحاجة لتحديث `crewai`، شغّل:
|
|
```shell
|
|
uv tool install crewai --upgrade
|
|
```
|
|
<Check>تم التثبيت بنجاح! أنت جاهز لإنشاء أول Crew!</Check>
|
|
</Step>
|
|
|
|
</Steps>
|
|
|
|
# إنشاء مشروع CrewAI
|
|
|
|
يقوم `crewai create crew` الآن بإنشاء مشروع crew بأسلوب JSON-first. توضع الـ Agents في `agents/*.jsonc`، وتوضع المهام وإعدادات الـ crew في `crew.jsonc`، ويحمّل `crewai run` هذا التعريف مباشرة.
|
|
|
|
<Steps>
|
|
<Step title="إنشاء هيكل المشروع">
|
|
- شغّل أمر `crewai` عبر CLI:
|
|
```shell
|
|
crewai create crew <your_project_name>
|
|
```
|
|
|
|
- سينشئ هذا مشروعًا جديدًا بالهيكل التالي:
|
|
```
|
|
my_project/
|
|
├── .gitignore
|
|
├── .env
|
|
├── agents/
|
|
│ └── researcher.jsonc
|
|
├── crew.jsonc
|
|
├── knowledge/
|
|
├── pyproject.toml
|
|
├── README.md
|
|
├── skills/
|
|
└── tools/
|
|
```
|
|
|
|
- إذا احتجت إلى البنية القديمة Python/YAML التي تحتوي على `crew.py` و `config/agents.yaml` و `config/tasks.yaml`، شغّل:
|
|
```shell
|
|
crewai create crew <your_project_name> --classic
|
|
```
|
|
|
|
</Step>
|
|
|
|
<Step title="تخصيص مشروعك">
|
|
- سيحتوي مشروعك على هذه الملفات الأساسية:
|
|
| الملف | الغرض |
|
|
| --- | --- |
|
|
| `crew.jsonc` | إعداد الـ crew وترتيب المهام والعملية وقيم الإدخال الافتراضية |
|
|
| `agents/*.jsonc` | تعريف دور كل Agent وهدفه و backstory والـ LLM والأدوات والسلوك |
|
|
| `.env` | تخزين مفاتيح API ومتغيرات البيئة |
|
|
| `tools/` | ملفات Python اختيارية لأدوات `custom:<name>` |
|
|
| `knowledge/` | ملفات معرفة اختيارية للـ Agents |
|
|
| `skills/` | ملفات skills اختيارية تطبق على الـ crew |
|
|
|
|
- ابدأ بتحرير `crew.jsonc` والملفات داخل `agents/` لتعريف سلوك الـ crew.
|
|
- استخدم قيم `{placeholder}` في نصوص الـ Agents والمهام، ثم ضع القيم الافتراضية في `inputs` داخل `crew.jsonc`. عند تشغيل `crewai run` ستطلب CLI أي قيم ناقصة.
|
|
- احتفظ بالمعلومات الحساسة مثل مفاتيح API في `.env`.
|
|
|
|
</Step>
|
|
|
|
<Step title="تشغيل الـ Crew">
|
|
- قبل تشغيل الـ Crew، تأكد من تنفيذ:
|
|
```bash
|
|
crewai install
|
|
```
|
|
- إذا كنت بحاجة لتثبيت حزم إضافية، استخدم:
|
|
```shell
|
|
uv add <package-name>
|
|
```
|
|
- لتشغيل الـ Crew، نفّذ الأمر التالي في جذر مشروعك:
|
|
```bash
|
|
crewai run
|
|
```
|
|
</Step>
|
|
</Steps>
|
|
|
|
## خيارات التثبيت للمؤسسات
|
|
|
|
<Note type="info">
|
|
للفرق والمؤسسات، يوفر CrewAI خيارات نشر مؤسسية تزيل تعقيد الإعداد:
|
|
|
|
### CrewAI AMP (SaaS)
|
|
|
|
- لا يتطلب أي تثبيت - فقط سجّل مجانًا على [app.crewai.com](https://app.crewai.com)
|
|
- تحديثات وصيانة تلقائية
|
|
- بنية تحتية مُدارة وقابلة للتوسع
|
|
- بناء Crews بدون كتابة كود
|
|
|
|
### CrewAI Factory (استضافة ذاتية)
|
|
|
|
- نشر بالحاويات على بنيتك التحتية
|
|
- يدعم أي مزود سحابي بما في ذلك النشر المحلي
|
|
- تكامل مع أنظمة الأمان الحالية
|
|
|
|
<Card title="استكشف خيارات المؤسسات" icon="building" href="https://share.hsforms.com/1Ooo2UViKQ22UOzdr7i77iwr87kg">
|
|
تعرّف على عروض CrewAI للمؤسسات وجدول عرضًا توضيحيًا
|
|
</Card>
|
|
</Note>
|
|
|
|
## الخطوات التالية
|
|
|
|
<CardGroup cols={2}>
|
|
<Card title="بدء سريع: Flow + وكيل" icon="code" href="/ar/quickstart">
|
|
اتبع البداية السريعة لإنشاء Flow وتشغيل طاقم بوكيل واحد وإنتاج تقرير.
|
|
</Card>
|
|
<Card
|
|
title="انضم إلى المجتمع"
|
|
icon="comments"
|
|
href="https://community.crewai.com"
|
|
>
|
|
تواصل مع مطورين آخرين واحصل على المساعدة وشارك تجاربك مع CrewAI.
|
|
</Card>
|
|
</CardGroup>
|