Selected work

Constraint-Based Duty Allocation

A pharmacy network is an operating environment: members, payments, schedules, staffing and data all have to work together.

My scope
Backend services · Integrations · Duty allocation · Production troubleshooting
  • Node.js
  • Python
  • FastAPI
  • Ollama
  • OR-Tools CP-SAT
  • SQL Server
  • Linux
  • Nginx

Conceptual architecture

Where does interpretation end and enforcement begin?

  1. Interpretation
  2. Validation
  3. Optimization

Ollama interprets natural-language duty rules. Validated constraints feed the OR-Tools CP-SAT solver; interpretation and allocation are separate stages.

SYSTEM LANDSCAPE
Pharmacy
operations
CONNECTED WORKFLOWS
Member servicesDuty schedulingPaymentsStaffingReportingIntegrations
An operating environment, not an isolated application.
6,000+Pharmacies in the production environment
35,000+Drug records in those systems

Member services · Payments · Scheduling
Staffing · Internal operations

Many workflows, one operating environment.

The Istanbul Chamber of Pharmacists operates production systems serving 6,000+ pharmacies and managing 35,000+ drug records. Within this environment, my work covers backend services, integrations, reporting and annual duty scheduling.

My contribution and scope

I develop backend services, third-party integrations and reporting, and troubleshoot production issues. I also designed an annual duty scheduling engine using Node.js, Python/FastAPI, Ollama and OR-Tools CP-SAT to turn natural-language rules into validated constraints.

Human rules. Validated constraints. A scheduling model.

  1. 01Natural-language rules
  2. 02Normalized constraints
  3. 03Validation
  4. 04CP-SAT optimization
  5. 05Allocation & review

Conceptual scheduling flow, with human review as an operational consideration.

From operational rules to an allocation model.

01

Rules before optimization

The scheduling engine converts natural-language duty rules with Ollama, validates the resulting constraints and passes them to OR-Tools CP-SAT. This separates interpretation from the constraint model used for annual allocation.

02

Connected workflows

Payment and SMS integrations connect pharmacy services to external providers. The backend also handles external-data retrieval, caching, geospatial rules and transactional batches.

03

Production responsibility

I troubleshoot Linux/Nginx issues affecting systems used by the pharmacy network, alongside developing the application backend.

Let’s talk about your system.

Working with scheduling rules or connected operational services? Let’s talk about your system.