AI Engineer in Morocco: Role, Skills and Roadmap
AI engineers turn models and LLMs into products that work in production. The role in Morocco, the skills employers want and a realistic junior roadmap.

What does an AI engineer do?
An AI engineer in Morocco, as elsewhere, builds software that relies on machine learning models or large language models (LLMs) and keeps it working in production. The job is less about inventing new algorithms and more about choosing the right model, connecting it to company data, wrapping it in an API or an interface, measuring its quality and controlling its cost.
Typical tasks in a Moroccan company or for a foreign client:
- Building a RAG assistant (retrieval-augmented generation) that answers questions from internal documents (how a RAG assistant is built).
- Adding an LLM feature to an existing product: classification of e-mails or tickets, extraction of fields from PDFs, summaries, a chatbot in French, Arabic or Darija.
- Training or fine-tuning a classic ML model (forecasting, scoring, anomaly detection) when an LLM is not the right tool.
- Writing the pipelines that prepare data, compute embeddings and refresh indexes.
- Designing AI agents and automations that call tools and APIs (AI agents explained).
- Setting up evaluation, monitoring and guardrails: test questions, error tracking, logging, access rules, cost per request.
AI engineer vs data scientist vs ML engineer vs data engineer
The titles overlap and every company uses them differently, but the centre of gravity of each role is clear.
| AI engineer | Data scientist | ML engineer | Data engineer | |
|---|---|---|---|---|
| Main goal | AI features in a product | Insights and models from data | Models trained, served and monitored at scale | Reliable data pipelines and warehouses |
| Typical work | LLM apps, RAG, agents, APIs | Analysis, experiments, statistics | Training pipelines, serving, MLOps | ETL / ELT, modelling, orchestration |
| Core tools | Python, LLM APIs, vector search, FastAPI, Docker | Python, pandas, scikit-learn, notebooks | PyTorch, MLflow, Kubernetes, feature stores | SQL, Python, Airflow, dbt, Spark |
| Output | A feature users touch | A report, a model, a recommendation | A model in production | Clean data on time |
In smaller companies, one person often covers several columns. The data side matters more than many beginners expect: an AI feature is only as good as the data it retrieves, which is why the data engineer role is a natural neighbour of this one.
Which skills do employers list?
Looking at AI engineer offers in Morocco and at remote offers open to Moroccan candidates, the same blocks come back.
Foundations
- Python: clean functions, packaging, typing, tests, async calls to APIs.
- SQL and data handling: joining, filtering and cleaning data before it reaches a model.
- Machine learning basics: train / test split, overfitting, metrics such as precision, recall and MAE. A first project like a sales forecast in Python covers the essentials.
- Git, Linux and Docker.
Deep learning and LLMs
- Deep learning: what a neural network, an embedding and a transformer are, with PyTorch or TensorFlow at a practical level.
- LLM APIs and open models: prompting, structured outputs, function calling, token limits, cost and latency trade-offs.
- RAG: chunking, embeddings, vector search (pgvector, a vector database or a search engine), reranking, citing sources.
- Agents and tools: when an agent is useful and when a simple, deterministic workflow is safer.
Production and MLOps
- APIs: FastAPI, Flask or a Java / Node back end calling the model.
- MLOps: versioning data and models, reproducible training, CI/CD, monitoring of quality and drift.
- Cloud: one provider in depth (Azure, AWS or GCP); Azure OpenAI, Bedrock or Vertex AI appear in many offers.
- Security and data protection: personal data handled with care, in line with Moroccan law 09-08 and the client's own rules.
A skill that is easy to show: evaluation
Most beginner projects stop at "it answers". Employers want to see that you measure. A minimal retrieval check in Python, run on a small set of questions whose correct source document you know:
def hit_rate(questions, retrieve, k=5):
"""Share of questions whose expected document appears in the top k results."""
hits = 0
for q in questions:
top_ids = [doc["id"] for doc in retrieve(q["text"], k=k)]
if q["expected_doc_id"] in top_ids:
hits += 1
return hits / len(questions)
# questions = [{"text": "What is the leave policy?", "expected_doc_id": "hr-007"}, ...]
# print(f"hit rate @5: {hit_rate(questions, retrieve):.0%}")
Fifty well-chosen questions and this function already tell you whether a change in chunking or embeddings improved retrieval, before you even look at the generated answers.
How much does an AI engineer earn in Morocco?
Public salary data for this specific role in Morocco is scarce. The one published grid we found with a dedicated AI engineer line is from the Moroccan job board Jobsquare (Salaires ingénieur informatique au Maroc en 2026, published April 2026). For an "IA engineer (LLMs, RAG, fine-tuning)" it lists:
| Level (Jobsquare 2026) | Monthly range in MAD |
|---|---|
| Junior | 15,000 to 22,000 |
| Mid-level | 25,000 to 45,000 |
| Senior | 45,000 to 80,000 |
Read these figures with care. The page states that its amounts are gross monthly salaries for the Casablanca and Rabat market and suggests 10 to 15% less in other cities, but it does not describe how the figures were collected. Treat them as one published reference, not as a survey: actual offers vary widely with the company, the sector, remote work for foreign clients and the real scope of the job. A title of "AI engineer" sometimes hides a data analyst or a developer role, and the reverse is also true.
A junior AI engineer roadmap (9 to 12 months)
This plan assumes basic programming skills and 10 to 15 hours per week.
| Period | Focus | Deliverable |
|---|---|---|
| Months 1 to 2 | Python, SQL, Git, Docker | A small API that reads a dataset and serves results |
| Months 3 to 4 | Machine learning basics with scikit-learn | A forecasting or classification model with honest metrics |
| Months 5 to 6 | Deep learning and embeddings | A semantic search over a few hundred documents |
| Months 7 to 8 | LLM apps and RAG | A RAG assistant with citations and an evaluation set |
| Months 9 to 10 | MLOps and cloud | The assistant deployed with CI/CD, logs and a cost estimate |
| Months 11 to 12 | Agents, portfolio, applications | One automation or agent project, a clear portfolio, targeted applications |
Portfolio projects that prove skills
Recruiters scan many GitHub links. The projects that stand out are complete, deployed and explained:
- A RAG assistant on a real document set (public regulations, a product manual, course notes) with source citations, a test set and a short write-up of what failed.
- A classic ML project with a baseline, a better model and a clear metric, so the recruiter sees you know when an LLM is not needed.
- An automation or agent that solves a real, small problem end to end: for example, the n8n prospecting automation turns a job post screenshot into a tracked offer and a personalised e-mail.
- A data-heavy platform contribution, if you have one: the D&A Studio data and AI platform combined a RAG assistant on company documents, anomaly detection and dashboards in one product.
For each project, the README should answer four questions: what problem, which architecture, how quality was measured, and what you would do next.
Working as a freelance AI developer in Morocco
Many companies want a first AI use case before hiring a full-time team, which opens room for freelancers. The missions that come up most often are document assistants, e-mail or ticket triage, data extraction from PDFs and automations between existing tools. A few practices make the difference:
- Start with a small, measurable scope: one process, one data source, one success metric agreed in writing.
- Price the first step, not the whole vision: a simple automation or a proof of concept first, then a quote for the full assistant once the data is known.
- Be explicit about data: where it is stored, which API sees it, what is logged, who can access it.
- Hand over properly: documentation, credentials in the client's accounts, a short video of the workflow.
As an example of how this can be packaged, the AI automation and RAG assistant service starts at 1,000 MAD for a simple automation, with RAG assistants quoted after a short call. For the business side of starting out, see finding your first clients as a freelance developer in Morocco.
Conclusion
The AI engineer role in Morocco sits between software engineering, data and machine learning. Employers want strong Python, a working understanding of ML and LLMs, RAG and evaluation skills, and the discipline to put a feature in production. Salary information is limited, so compare published references with real offers. Two or three deployed projects with honest metrics remain the clearest proof for a junior profile.
To see these skills applied in real projects, visit the Data & AI engineer profile.
- AI engineer
- Morocco
- Career
- LLM
- RAG
- MLOps
- Roadmap
Share this article

About the author
Anass Essadikine
Data & AI Engineer and Software Engineer based in Casablanca, Morocco. I build data platforms, Power BI dashboards, RAG assistants and Next.js / Spring Boot applications.
Related projects

D&A Studio: Data & AI Platform (PaaS)
A platform that brings geospatial tracking data, an AI assistant on company documents, anomaly detection and BI dashboards into one place.

E-commerce Platform with an AI Sales Assistant
A full rebuild of an online retailer's shop in Morocco: a bilingual storefront, a complete back office and an AI sales assistant that understands Darija and hands over to WhatsApp.

AI Job Application Automation with n8n
An n8n workflow that turns a screenshot of a job post sent on Telegram into a tracked offer, then writes and sends a personalised application email with the right CV attached.
Frequently asked questions
A data scientist explores data, runs experiments and builds models to answer business questions. An AI engineer turns models and LLMs into product features that run in production, with APIs, monitoring, evaluation and cost control. In small teams one person often does both.
Most offers ask for an engineering degree or a master's, but strong deployed projects, a clear GitHub and solid Python and SQL skills can compensate, especially for startups, agencies and remote roles. Internships (PFE) remain the most common entry route for students.
Reliable public data is scarce. The Jobsquare 2026 grid lists 15,000 to 22,000 MAD gross per month for a junior AI engineer in Casablanca and Rabat, without describing its method. Treat it as one reference and compare it with the ranges shown in real offers.
You do not need to train large models, but you should understand embeddings, transformers, tokens and why models hallucinate. That knowledge helps you design retrieval, prompts and evaluation instead of guessing when an answer is wrong.
A RAG assistant on a real public document set, with source citations and a small evaluation set, is the most useful first project. It covers Python, embeddings, vector search, prompting, an API and deployment in one deliverable that recruiters understand quickly.


