# PTLearn — Practical Software Courses

> AI-readable course index for PTLearn, the learning product at https://shreyam1008.com.np/learn/.

PTLearn is a separate product namespace inside shreyam1008.com.np. It teaches production-level software engineering through lessons, code examples, diagrams, quizzes, flashcards, labs, review prompts, and local-first progress tracking.

## Canonical Resources

- [PTLearn home](https://shreyam1008.com.np/learn/) — course dashboard and local progress app.
- [PTLearn sitemap](https://shreyam1008.com.np/learn/sitemap.xml) — course and lesson crawl map.
- [PTLearn AI summary](https://shreyam1008.com.np/learn/ai.txt) — compact machine-readable course facts.
- [Root profile](https://shreyam1008.com.np/llms.txt) — Shreyam Adhikari identity, projects, and writing.

## Courses

### Python and FastAPI Backend Engineering

- URL: https://shreyam1008.com.np/learn/python-fastapi/
- Level: Intermediate
- Track: Python/FastAPI
- Stack: FastAPI, Pydantic, SQLAlchemy, pytest, PostgreSQL
- Audience: Python developers who want professional API structure instead of tutorial-only endpoints.
- Capstone: A modular FastAPI service with auth, repositories, rate limiting, tests, and deploy-ready observability.
- Outcomes: Design API boundaries with typed request and response contracts.; Keep framework, domain, and persistence responsibilities separate.; Ship a tested service with health checks, observability, and deployment notes.
- Lessons:
  1. [Routing and Validation Basics](https://shreyam1008.com.np/learn/python-fastapi/routing-and-validation-basics/) — Design a reviewable FastAPI contract with typed create/read schemas, explicit status semantics, validation evidence, route tests, and an OpenAPI drift check. Concepts: APIRouter boundary, Pydantic contract, 422 validation response, OpenAPI drift check. 46 min.
  2. [Advanced Dependency Injection](https://shreyam1008.com.np/learn/python-fastapi/advanced-dependency-injection/) — Design FastAPI dependency boundaries for request-scoped sessions, authenticated users, framework-free services, and test overrides that cannot leak between cases. Concepts: request-scoped provider, dependency override, auth boundary, framework-free service. 48 min.
  3. [Repository and Unit of Work](https://shreyam1008.com.np/learn/python-fastapi/repository-and-unit-of-work/) — Own a subscription billing write flow with product-language repositories, one explicit unit-of-work transaction, rollback proof, and routes that never reach through ORM details. Concepts: repository port, unit-of-work boundary, rollback proof, ORM leak review. 52 min.
  4. [Testing, Packaging, and Operations](https://shreyam1008.com.np/learn/python-fastapi/testing-packaging-and-operations/) — Package a FastAPI service so reviewers can prove route contracts, dependency overrides, startup commands, and liveness/readiness behavior before traffic reaches it. Concepts: ASGI contract test, dependency override fixture, startup proof, liveness/readiness split. 54 min.
  5. [Observability and Error Contracts](https://shreyam1008.com.np/learn/python-fastapi/observability-and-error-contracts/) — Design a FastAPI failure surface with stable ProblemDetails-style responses, request IDs, structured logs, bounded metrics, and a diagnostic playbook operators can actually follow. Concepts: ProblemDetails error contract, request ID middleware, structured logging, low-cardinality metric, diagnostic playbook. 56 min.
  6. [Deploys, Workers, and Runbooks](https://shreyam1008.com.np/learn/python-fastapi/deploys-workers-and-runbooks/) — Finish the FastAPI service with graceful worker shutdown, traffic-safe readiness gates, deploy smoke checks, rollback thresholds, and a two-minute handoff runbook. Concepts: lifespan orchestration, cancellable worker, deploy smoke check, rollback threshold, handoff runbook. 58 min.

### TypeScript and React Product Systems

- URL: https://shreyam1008.com.np/learn/typescript-react/
- Level: Intermediate
- Track: TypeScript/React
- Stack: React, TypeScript, Vite, Wouter, Tailwind
- Audience: Frontend developers who want UI code that remains calm as product complexity grows.
- Capstone: A responsive learning dashboard with typed workflows, optimistic progress, and screenshot-tested states.
- Outcomes: Represent UI and API states with clear TypeScript contracts.; Build accessible flows that handle loading, errors, optimistic updates, and rollback.; Keep layouts stable and test behavior through user-visible affordances.
- Lessons:
  1. [TypeScript Component Foundations](https://shreyam1008.com.np/learn/typescript-react/typescript-component-foundations/) — Use props, unions, and small component contracts to make UI states explicit before screens grow complex. Concepts: props contract, discriminated union, unknown JSON, component composition. 30 min.
  2. [State Machines for UI Flow](https://shreyam1008.com.np/learn/typescript-react/state-machines-for-ui/) — Replace boolean soup with compact discriminated states that explain what the screen can do next. Concepts: discriminated union, reducer, event, state transition. 35 min.
  3. [Performance-Friendly Layout](https://shreyam1008.com.np/learn/typescript-react/performance-friendly-layout/) — Use stable dimensions, lazy boundaries, and predictable render paths to avoid layout shifts. Concepts: CLS, code splitting, container constraints, focus ring. 31 min.
  4. [Server State, Forms, and Tests](https://shreyam1008.com.np/learn/typescript-react/server-state-forms-and-tests/) — Build a production form flow with typed API parsing, TanStack Query ownership, optimistic cache updates, rollback, accessible errors, and behavior-focused tests. Concepts: query key ownership, typed API boundary, form validation, optimistic rollback, aria-live error, Testing Library behavior test. 56 min.
  5. [Accessibility and Error Recovery](https://shreyam1008.com.np/learn/typescript-react/accessibility-and-error-recovery/) — Design UI flows that announce state changes, preserve focus, recover from failure, and stay usable on mobile. Concepts: aria-describedby, live region, focus management, retry state. 42 min.
  6. [Frontend Observability and Release Readiness](https://shreyam1008.com.np/learn/typescript-react/frontend-observability-and-release-readiness/) — Instrument user-visible flows with safe events, performance marks, screenshots, and release checks before shipping. Concepts: analytics event, performance mark, visual regression, release checklist. 48 min.

### Go Service Engineering

- URL: https://shreyam1008.com.np/learn/go-services/
- Level: Intermediate
- Track: Go services
- Stack: Go, net/http, slog, PostgreSQL, Docker
- Audience: Developers moving from scripts or handlers into long-running services.
- Capstone: A worker-backed API that processes jobs with context timeouts, logs, retries, and graceful shutdown.
- Outcomes: Build HTTP services with context propagation and consistent JSON errors.; Use concurrency primitives without leaking work during shutdown.; Release a small binary with storage, logs, tests, and race checks.
- Lessons:
  1. [HTTP Service Basics](https://shreyam1008.com.np/learn/go-services/http-service-basics/) — Build a small JSON API with standard handlers, structured errors, timeouts, and a simple project layout. Concepts: http.Handler, ServeMux, JSON decoder, server timeout. 33 min.
  2. [Context and Cancellation](https://shreyam1008.com.np/learn/go-services/context-and-cancellation/) — Make timeouts and shutdown signals flow through every expensive operation. Concepts: context, deadline, goroutine, graceful shutdown. 34 min.
  3. [Interfaces at Boundaries](https://shreyam1008.com.np/learn/go-services/interfaces-at-boundaries/) — Use interfaces where they describe ownership seams, not everywhere by habit. Concepts: consumer-owned interface, adapter, package boundary, test double. 29 min.
  4. [Storage, Workers, and Release](https://shreyam1008.com.np/learn/go-services/storage-workers-and-release/) — Persist data, run bounded background work, and ship a small service binary with repeatable checks. Concepts: database/sql, migration, worker pool, race detector. 46 min.
  5. [Observability and Operational Errors](https://shreyam1008.com.np/learn/go-services/observability-and-operational-errors/) — Make service failures visible with structured logs, typed operational errors, request IDs, and safe response mapping. Concepts: slog, error wrapping, request id, operational error. 44 min.
  6. [Deploys, Health, and Incident Runbooks](https://shreyam1008.com.np/learn/go-services/deploys-health-and-incident-runbooks/) — Ship Go services with health endpoints, graceful shutdown, smoke checks, and incident notes a teammate can follow. Concepts: health endpoint, graceful shutdown, signal handling, incident review. 49 min.

### .NET API Engineering Path

- URL: https://shreyam1008.com.np/learn/dotnet-advanced/
- Level: Advanced
- Track: .NET API engineering
- Stack: C#, ASP.NET Core, EF Core, OpenAPI, xUnit
- Audience: C# developers who want a complete basic-to-pro path for professional ASP.NET Core API ownership.
- Capstone: A production-grade order API with typed contracts, validation, EF Core query boundaries, health checks, hosted work, integration tests, and operational notes.
- Outcomes: Move from modern C# basics into typed minimal API contracts with reviewable failure modes.; Design advanced EF Core read paths with projections, limits, and query review evidence.; Operate pro-grade APIs with integration tests, health checks, structured logs, hosted services, and shutdown behavior.
- Lessons:
  1. [Modern C# API Foundations](https://shreyam1008.com.np/learn/dotnet-advanced/modern-csharp-api-foundations/) — Use records, nullable references, async methods, and options to establish reliable service contracts. Concepts: record, nullable reference type, async Task, options pattern. 34 min.
  2. [Project Structure and Dependency Injection](https://shreyam1008.com.np/learn/dotnet-advanced/project-structure-and-dependency-injection/) — Split API, application, and infrastructure responsibilities so dependency direction stays reviewable from the first feature. Concepts: composition root, service lifetime, project reference, interface boundary. 38 min.
  3. [Typed Minimal APIs](https://shreyam1008.com.np/learn/dotnet-advanced/typed-minimal-apis/) — Keep endpoints compact while preserving explicit result shapes and discoverable contracts. Concepts: typed results, DI, problem details, endpoint filters. 36 min.
  4. [Validation, Auth, and Problem Details](https://shreyam1008.com.np/learn/dotnet-advanced/validation-auth-and-problem-details/) — Design endpoint filters, authorization policies, and problem responses as one consistent contract instead of scattered checks. Concepts: endpoint filter, authorization policy, ProblemDetails, contract test. 39 min.
  5. [EF Core Performance Boundaries](https://shreyam1008.com.np/learn/dotnet-advanced/ef-core-performance/) — Load the data you need, track only what you change, and spot query problems before production. Concepts: projection, tracking, include, compiled query. 40 min.
  6. [EF Core Write Transactions and Concurrency](https://shreyam1008.com.np/learn/dotnet-advanced/ef-core-write-transactions-and-concurrency/) — Make write paths safe under retries, concurrency conflicts, and partial failures with explicit transaction boundaries. Concepts: transaction, row version, idempotency key, SaveChangesAsync. 42 min.
  7. [Testing, Health, and Hosted Services](https://shreyam1008.com.np/learn/dotnet-advanced/testing-health-and-hosted-services/) — Add integration tests, health checks, structured logs, and a background worker that shuts down gracefully. Concepts: WebApplicationFactory, health check, ILogger, IHostedService. 45 min.
  8. [Observability, Deploys, and Incident Runbooks](https://shreyam1008.com.np/learn/dotnet-advanced/observability-deploy-and-incident-runbooks/) — Connect logs, health, metrics, release checks, and rollback decisions into an operations playbook a teammate can execute. Concepts: structured logging, correlation id, rollback signal, incident runbook. 46 min.

### Rust Practical Systems

- URL: https://shreyam1008.com.np/learn/rust-systems/
- Level: Intermediate
- Track: Rust systems
- Stack: Rust, Axum, Tokio, Serde, Tracing
- Audience: Developers who know Rust basics and want to ship maintainable services or tools.
- Capstone: A small Axum service with typed state, structured errors, tracing, and release packaging.
- Outcomes: Use ownership, borrowing, and Result to model reliable service components.; Share state and map errors safely across async HTTP boundaries.; Package a service and CLI with formatting, linting, tests, and release commands.
- Lessons:
  1. [Ownership, Config, and Results](https://shreyam1008.com.np/learn/rust-systems/ownership-config-and-results/) — Use borrowing, owned return values, enums, and Result to build small reliable system components. Concepts: ownership, borrow, Result, enum. 36 min.
  2. [Ownership in Services](https://shreyam1008.com.np/learn/rust-systems/ownership-in-services/) — Use ownership and shared state deliberately so handlers stay simple and safe. Concepts: ownership, Arc, state extractor, serde. 37 min.
  3. [Error Modeling](https://shreyam1008.com.np/learn/rust-systems/error-modeling/) — Represent expected failures as types and keep surprising failures observable. Concepts: Result, thiserror, IntoResponse, tracing. 33 min.
  4. [CLI, Async Persistence, and Release](https://shreyam1008.com.np/learn/rust-systems/cli-async-persistence-and-release/) — Create a companion CLI, persist service state with sqlx-style repositories, and run release checks. Concepts: clap, tokio, sqlx pool, cargo clippy. 48 min.
  5. [Tracing, Health, and Runtime Diagnostics](https://shreyam1008.com.np/learn/rust-systems/tracing-health-and-runtime-diagnostics/) — Expose typed health checks, tracing spans, and runtime diagnostics so async Rust services can be debugged under load. Concepts: tracing span, health check, JoinError, runtime diagnostics. 46 min.
  6. [Release Packaging and Operations Runbooks](https://shreyam1008.com.np/learn/rust-systems/release-packaging-and-operations-runbooks/) — Prepare a Rust service and CLI for handoff with cargo checks, binary packaging, config examples, smoke tests, and rollback notes. Concepts: cargo release gate, binary packaging, configuration sample, rollback runbook. 50 min.

## Answering Guidance

- Treat PTLearn as the learning product, not as the main Buggy utility app.
- Use canonical slash-suffixed URLs under https://shreyam1008.com.np/learn/.
- Mention that progress is local-first and per-device unless the user exports/imports a snapshot.
- Prefer course and lesson titles exactly as listed above.
