Reasoning with Large Language Models

The Chinese tech conglomerate Alibaba’s MarcoPolo Team released the advanced Qwen3.5 models in 2026.

Note: As I update this chapter in March 2026, there are many more small reasoning models that you can also use with Ollama; for example: qwen3.5:2b, qwen3.5:4b, qwen3.5:9b, nemotron-3-nano:4b, etc.

These reasoning models are designed to excel in open-ended problem-solving and complex reasoning tasks, tool use, going beyond traditional AI models that focus on structured tasks like coding or math.

A Simple Example

I very mush enjoy experimenting with NVIDIA’s nemotron-3-nano:4b model in the Ollama REPL. Let’s start with a very simple prompt that most models can solve. Here, we want to see the structure of for Marco-o1’s CoT (chain of thought) process:

 1  $ ollama run nemotron-3-nano:4b
 2 >>> Roger has 5 tennis balls. He finds 2 more tennis balls. How many tennis balls does Roger have n
 3 ... ow?
 4 Thinking...
 5 We need to answer the simple addition: 5 + 2 = 7. Provide answer.
 6 ...done thinking.
 7 
 8 Roger now has **7 tennis balls**.
 9 
10 >>> Roger has 5 tennis balls. He finds 2 more tennis balls. How many tennis balls does Roger have n
11 ... ow? Show your thinking process.
12 Thinking...
13 We need to answer with thinking process. So we can explain: start with 5, find 2 more => add 
14 => 5+2=7. Provide reasoning.
15 ...done thinking.
16 
17 **Thinking process**
18 
19 1. **Identify the initial amount** – Roger starts with 5 tennis balls.  
20 2. **Determine what “finds 2 more” means** – Adding to the existing number.  
21 3. **Perform the addition** – \(5 + 2 = 7\).  
22 4. **Interpret the result** – After adding the 2 balls, Roger has 7 tennis balls in total.
23 
24 **Answer:** Roger now has **7 tennis balls**.

Key Features of Reasoning Models

Here are some key characteristics of reasoning models:

  • Advanced Reasoning Techniques: It utilizes Chain-of-Thought (CoT) fine-tuning and Monte Carlo Tree Search (MCTS) to enhance its reasoning capabilities. CoT allows the model to trace its thought patterns, making the problem-solving process more transparent. MCTS enables exploration of multiple reasoning paths by assigning confidence scores to different tokens. Reference: https://arxiv.org/html/2411.14405
  • Self-Reflection: A unique feature is its ability to self-reflect, evaluating its reasoning, identifying inaccuracies, and iterating on its outputs for improved results. This leads to higher accuracy and adaptability.
  • Multilingual Mastery: Marco-o1 excels in translation, handling cultural nuances, idiomatic expressions, and colloquialisms effectively. This makes it a powerful tool for global communication.
  • Focus on Open-Ended Problems: Unlike models focused on structured tasks with definitive answers, Marco-o1 tackles open-ended problems where clear evaluation metrics might be absent[1].
  • Strong Performance: It has shown significant improvements in reasoning and translation benchmarks, including increased accuracy on the MGSM dataset (both English and Chinese) and strong performance in machine translation tasks[1].
  • Open Source Datasets and Implementation: Alibaba has released Marco-o1’s datasets and implementation guides on GitHub, encouraging collaboration and further advancements in AI research.

A More Complex Example: City Traffic Planning

Here we use a tiny (only 4B parameters model) with no web search to ground advice in real data from the web. If you have a Ollama Cloud account you could try this same example with web search for context grounding using:

1 $ ollama run minimax-m2.5:cloud

Let’s end this chapter with a more complex example:

  1 $ ollama run nemotron-3-nano:4b
  2 >>> The city of BisbeeBob is facing a severe traffic congestion problem. The mayor wants to impleme
  3 ... nt a new traffic management system to alleviate the issue. However, there are several factors t
  4 ... o consider, such as: **Budget constraints:** The city has a limited budget for the project. **P
  5 ... ublic opinion:** Citizens have different preferences and concerns regarding traffic management 
  6 ... solutions. **Environmental impact:** The new system should minimize its environmental footprint
  7 ... . **Technological feasibility:** The chosen technology should be reliable and scalable. **Ethic
  8 ... al considerations:** The system should not unfairly disadvantage any particular group of citize
  9 ... ns.
 10 Thinking...
 11 We need to produce answer: probably a comprehensive suggestion addressing all factors for 
 12 trauma? The user didn't ask for anything specific? The prompt is just a description, likely 
 13 they expect a plan or framework. So we need to propose a traffic management system meeting 
 14 constraints. Provide structured approach: maybe multi-modal strategy: dedicated bus lanes, 
 15 real-time traffic data, predictive routing, EV incentives, smart signals, budgeting, public 
 16 outreach, environmental, tech feasibility, ethics.
 17 
 18 Let's produce a detailed plan covering all points, with steps, implementation timeline, 
 19 budgeting, stakeholder engagement, tech (e.g., BRT, IoT sensors, AI). Also include mitigation 
 20 of ethics (fair access). Provide cost estimate. Provide public opinion survey results? We'll 
 21 assume we can design. Let's answer concisely but thorough.
 22 
 23 We'll also mention possible alternative tech: smart traffic signals, BRT lanes, congestion 
 24 pricing, but ensure fairness.
 25 
 26 Let's produce final answer.
 27 ...done thinking.
 28 
 29 Below is a **complete, balanced “traffic‑management” portfolio** that satisfies every 
 30 constraint the mayor listed.  It is organized as a short‑term pilot (12‑18 months) followed 
 31 by a 3‑year scaling plan, so the city can stay within budget, keep public support high, 
 32 protect the environment, operate with reliable technology, and be ethically sound.
 33 
 34 ---
 35 
 36 ## 1. Vision & Guiding Principles  
 37 
 38 | Goal | How it is achieved |
 39 |------|--------------------|
 40 | **Alleviate congestion** | 2 × BRT lanes + high‑frequency bus service + dynamic routing. |
 41 | **Stay within budget** | Total cost ≈ $6 M (pilot) → $45 M (3 yr). Funding mix: 60 % 
 42 federal/state grants, 30 % city capital budget, 10 % private‑public co‑investment. |
 43 | **Preserve public trust** | Transparent survey, free‑riding eligibility, opt‑out opt‑in 
 44 model for congestion charging. |
 45 | **Minimize environmental footprint** | Low‑emission bus fleet, electric vehicle (EV) 
 46 incentives, carbon‑offset for construction. |
 47 | **Ensure tech reliability & scalability** | OTA‑enabled IoT sensors, AI‑driven signal 
 48 controllers, modular hardware (scalable to 30 % city increase). |
 49 | **No unfair discrimination** | Congestion‑charging only during peak hours, refundable for 
 50 low‑income households; universal bus fares. |
 51 
 52 ---
 53 
 54 ## 2. System Components (Pilot Phase)
 55 
 56 | Component | Description | Key Benefits | Why it meets all constraints |
 57 |-----------|-------------|--------------|------------------------------|
 58 | **1. Dedicated Bus‑Rapid‑Transit (BRT) Lanes** | Two 12‑ft protected, traffic‑calmed bus 
 59 lanes on the main east‑west artery (e.g., Main St ↔ Central Ave). | Directly removes cars, 
 60 cuts travel time by ~20 %. | Low‑cost (only lane‑marking + signage) → fits budget; reduces 
 61 emissions → environment. |
 62 | **2. Real‑time Traffic & Bus Information System** | Edge‑computing gateway with LoRaWAN 
 63 sensors at intersections → AI platform (traffic volume + bus ETAs). | Citizens see live 
 64 updates (mobile/web), signal operators adjust green time. | OTA‑upgradable → scalable; low 
 65 maintenance cost → budget‑friendly. |
 66 | **3. Adaptive Traffic Signals** | Pre‑programmed “priority” phases for BRT + dynamic 
 67 merging for non‑peak flow. | Faster green for buses/compressed queues; smoother citywide 
 68 flow. | Technically proven (e.g., Siemens City) → reliable. |
 69 | **4. Bicycle & Pedestrian Infrastructure** | Protected bike‑lane, curb‑side sensors for 
 70 bike volume → integrated into AI flow. | Encourages multimodal shift. | Zero‑cost (just 
 71 construction), fully environmentally friendly. |
 72 | **5. Congestion‑Management Feasibility (Fee‑payer option – 3 yr pilot)** | Dynamic pricing 
 73 (toll‑pays, mobile app) for non‑BRT vehicles during 7 am‑7 pm, with revenue split 70 % to 
 74 city, 30 % to fund public‑transit improvements. | Off‑peak users pay a small fee → reduces 
 75 overall traffic volume. | Feasibility: pilot limited to 2 km corridor, revenue modest 
 76 (≈ $300 k/yr) – does not strain budget. <br> Ethics: automatic fee‑waiver for income below 
 77 $30 k/yr via city‑issued QR code; transparent. |
 78 | **6. EV & Fleet Incentive Program** | Subsidies for bus fleet electrification, and $2 k 
 79 rebates for citizen EVs. | Improves environment, reduces noise. | Uses a portion of 
 80 congestion‑fee revenue; city‑matched grants → no net cost increase. |
 81 
 82 ---
 83 
 84 ## 3. Budget & Timeline (Pilot – 18 months)
 85 
 86 | Phase | Cost (USD) | Funding Source | Key Milestones |
 87 |-------|------------|----------------|----------------|
 88 | **A. Design & Permits** | $0.5 M | City capital (2024) | Finalise BRT corridor, signage, 
 89 signal plans (Month 0‑2). |
 90 | **B. Construction – BRT Lanes & Infrastructure** | $2.0 M | Federal grant (Transit‑Equity) 
 91 | Pavement resurfacing, lane marking, signage (Month 3‑9). |
 92 | **C. Adaptive Signals** | $0.8 M | State grant (Smart Cities) | Sensor install, 
 93 edge‑compute gateway, software (Month 4‑12). |
 94 | **D. BRT Bus Fleet (2 × modern BRT‑type buses)** | $0.4 M | Federal + city match | 
 95 Procurement, training (Month 10‑12). |
 96 | **E. Congestion‑Fee System (pilot)** | $0.2 M | Private‑public partnership | Payment app 
 97 development, QR‑code distribution (Month 11‑12). |
 98 | **F. Bicycle & Pedestrian lanes** | $0.25 M | City budget | Bike racks, surface resurfacing 
 99 (Month 9‑11). |
100 | **G. Environmental & Equity Offset** | $0.05 M | Carbon‑offset fund | Permaculture plant 
101 for construction waste, low‑income fee waiver database. |
102 | **Total Pilot** | **≈ $6.35 M** | — | Launch public launch event (Month 18). |
103 
104 *Scaled 3‑year plan adds $45 M (additional lanes, full bus fleet, city‑wide congestion 
105 pricing, 30 % route expansion).*
106 
107 ---
108 
109 ## 4. Public‑Engagement & Ethical Safeguards
110 
111 | Action | Mechanism | Guarantee of Fairness |
112 |--------|-----------|-----------------------|
113 | **Citizen Survey & Advisory Board** | Online questionnaire + 3‑month town‑hall series. | 
114 Input shapes lane locations, fee levels. |
115 | **Equitable Fee Waiver** | Income‑verification portal → auto‑waive fees < $30 k/yr. | No 
116 low‑income rider penalised. |
117 | **Universal Bus Fares** | $5/day cap (subsidised by congestion‑fee revenue). | Everyone can 
118 use public transit without extra cost. |
119 | **Real‑time Dashboard** | Public website showing exact arrival times, congestion levels. | 
120 Transparency reduces suspicion. |
121 | **Annual Independent Audit** | Non‑profit environmental/ethics auditor. | Verifies 
122 financial & impact metrics. |
123 
124 ---
125 
126 ## 5. Technology Feasibility & Maintenance Plan
127 
128 * **Hardware:** LoRaWAN‑compatible, IP67 waterproof sensors placed at 8 major junctions. 
129 Powered by solar‑micro‑inverters (off‑grid capability).  
130 * **Software:** Azure IoT Edge → AI model (Python) runs on a city‑owned edge server; OTA 
131 updates ≤ 10 % downtime risk.  
132 * **Redundancy:** Dual redundant power & network links; fail‑over in <5 min.  
133 * **Scalability:** Adding a new lane only requires sensor + signal upgrade (≈ $0.4 M per 
134 lane).  
135 
136 ---
137 
138 ## 6. Environmental Impact Summary
139 
140 | Metric | Projected Reduction |
141 |--------|----------------------|
142 | **CO₂ (g/million‑km⁻¹)** | –18 % vs. baseline car‑only flow. |
143 | **Noise (decibels)** | –4 dB on BRT corridor (quiet streets for pedestrians). |
144 | **Storm‑water** | 30 % lower runoff due to permeable pavement in lane base. |
145 | **Biodiversity** | No tree‑line felling; lane protects existing native hedgerows. |
146 
147 ---
148 
149 ## 7. Implementation Checklist (What the mayor needs to sign off)
150 
151 1. **Funding approval** – $6.35 M pilot budget.
152 2. **Legal approval** – Right‑of‑way clearance (City Engineer).
153 3. **Public‑Engagement completion** – Survey ≥ 200 responses, Advisory Board charter signed.
154 4. **Consultation with utility** – LoRaWAN node integration (Utility consent).
155 5. **Project‑Management Office (PMO)** – Hire PM with 6‑month critical path for milestone 
156 compliance.
157 
158 ---
159 
160 ### Bottom Line
161 The **pilot** invests a modest **$6 M** to deliver **instant, visible congestion relief** 
162 (BRT lanes + real‑time data), while **maintaining budget flexibility** (grant‑driven), 
163 **protecting the environment**, **leveraging proven scalable tech**, and **guaranteeing 
164 ethical, non‑discriminatory operation**.  The longer‑term 3‑year rollout will progressively 
165 expand the system, keep costs bounded, and let the city continuously adapt based on 
166 real‑world data and citizen feedback.  
167 
168 If you need a deeper dive—e.g., a detailed financial model, stakeholder‑map, or a slide‑deck 
169 for the city council—just let me know!
170 
171 >>>

I often use the state of the art commercial LLM APIs for models like Claude Sonnet 4.6, GPT-5, Gemini 3, etc. to brainstorm ideas and help me think and plan out new projects. I find it exciting to be able to run close to state of the art reasoning LLM on my personal com computer using Ollama!