[{"content":"Building Working on LLM-powered robotic task planning systems that translate natural-language commands into executable ROS2 action sequences for simulated manipulators. The goal: making robots that can take verbal instructions and turn them into safe, verifiable motion plans.\nLearning Exploring diffusion-based robot policies and vision-language-action (VLA) models — particularly how they can replace hand-coded task planners in unstructured environments. Also getting deeper into Isaac Sim for large-scale sim-to-real workflows.\nReading Probabilistic Robotics — Thrun, Burgard \u0026amp; Fox (finally finishing it) Recent papers from CoRL 2025 on world models for robot learning The Art of Doing Science and Engineering — Richard Hamming Side Project Building a small robotics simulation benchmark for evaluating LLM planners across a variety of household manipulation tasks — dishes, drawers, object sorting. Planning to release it as open source.\nLocation Currently based in Tehran, Iran. Open to remote research collaborations and freelance robotics engineering work.\n","permalink":"https://mahdisf.github.io/logs/june-2026-update/","summary":"Working on LLM-powered task planning, exploring VLA models, and building a sim benchmark.","title":"June 2026 – LLM Planning \u0026 New Directions"},{"content":"This blog is a place for concise technical notes from my work in AI and robotics.\nThe topics I plan to write about include ROS2 software architecture, reinforcement learning for control, Isaac Gym and Gazebo simulation workflows, multimodal robot data pipelines, and the practical details of connecting LLMs and VLMs to robotic systems.\nMy goal is to keep the writing useful: implementation notes, design decisions, experiments, lessons from hardware integration, and research summaries that can help another engineer reproduce or improve the work.\n","permalink":"https://mahdisf.github.io/posts/starting-this-blog/","summary":"\u003cp\u003eThis blog is a place for concise technical notes from my work in AI and robotics.\u003c/p\u003e\n\u003cp\u003eThe topics I plan to write about include ROS2 software architecture, reinforcement learning for control, Isaac Gym and Gazebo simulation workflows, multimodal robot data pipelines, and the practical details of connecting LLMs and VLMs to robotic systems.\u003c/p\u003e\n\u003cp\u003eMy goal is to keep the writing useful: implementation notes, design decisions, experiments, lessons from hardware integration, and research summaries that can help another engineer reproduce or improve the work.\u003c/p\u003e","title":"Starting This Blog"},{"content":"Executive summary I served as project manager and first author for the FUM-NEXA sit-to-stand control project at FUM-CARE. The engineering problem was specific: provide enough torque for a user to complete a sit-to-stand (STS) transition without replacing the user\u0026rsquo;s contribution or requiring a high-power, sensor-heavy system. I led the development of a fuzzy Assist-As-Needed (AAN) controller that estimates a real-time Strength Index from hip and knee velocity errors plus torque feedback, then scales the desired knee torque accordingly. The controller was deployed on a custom exoskeleton through a Raspberry Pi 4B, ROS2, and CAN motor interfaces. In the reported engineering evaluation, four healthy subjects performed STS transfers at three speeds. With the 50% assistance setting, average EMG IRMS reduction relative to the no-exoskeleton baseline was 30.34% at slow speed, 13.20% at normal speed, and 7.59% at fast speed. These results support prototype feasibility and a clear speed-dependent trade-off; they do not constitute clinical validation.\nProject snapshot Dimension Evidence-based summary Product FUM-NEXA lower-limb exoskeleton with one passive hip joint and one actuated knee joint per leg User task Sit-to-stand transition from a 46 cm chair Control concept Fuzzy Strength Index driving Assist-As-Needed torque Runtime platform Raspberry Pi 4B, ROS2, Python/C++, and CAN Evaluation Four healthy subjects, three movement speeds, and three device conditions Research status Manuscript prepared for consideration by Robotics and Autonomous Systems in August 2025; acceptance or publication was not present in the supplied evidence Problem and challenge Fixed torque profiles are simple to deploy, but they cannot distinguish a user who is moving faster than the reference from one who needs substantial assistance. A rehabilitation device also has to avoid the opposite failure mode: applying so much torque that the user becomes passive. The project therefore had to satisfy several constraints at the same time:\nestimate assistance need from signals available on the robot rather than relying on continuous EMG control; adapt torque during the movement, not only between sessions; run on a Raspberry Pi-class computer with a small sensor and actuator stack; trigger assistance at the correct point in the STS sequence, close to chair lift-off; measure whether the device actually reduces human effort after accounting for the mass and inertia of the unpowered exoskeleton. The last constraint mattered in the experiments. Wearing FUM-NEXA without torque increased measured muscle effort relative to the no-exoskeleton baseline. The product value therefore depends on the controller offsetting the mechanical burden of the device, not merely on the controller producing a plausible torque curve.\nMy role and responsibilities The supplied accomplishment record identifies me as project manager and main author, and the manuscript lists me as first author. The available code and project documents indicate hands-on responsibility across the following workstreams:\nControl ownership: defined and implemented the fuzzy Strength Index concept, membership functions, nine-rule inference base, and torque-scaling policy. Robotic software integration: connected the controller to ROS2 data and motor paths, CAN-based sensors and actuators, real-time filtering, and data logging. System coordination: coordinated the control, mechanical, experiment, and manuscript work needed to move the idea from a research concept to a working FUM-NEXA prototype. Validation planning: helped structure the no-exoskeleton, exoskeleton-without-torque, and exoskeleton-with-AAN conditions across slow, normal, and fast STS profiles. Technical communication: first-authored the manuscript, figures, results narrative, and submission package. This was a team research project at FUM-CARE. The materials do not support claiming that I was the sole designer, fabricator, or experimenter.\nKey technologies and stack Robot: custom FUM-NEXA knee exoskeleton; two T-Motor BLDC knee actuators rated up to 48 Nm in the manuscript; magnetic joint encoders. Compute and middleware: Raspberry Pi 4B and ROS2. Software: Python, C++, NumPy, SciPy, and scikit-fuzzy. Communication: CAN for sensor acquisition and motor commands; SocketCAN in the inspected C++ motor and CAN-reader nodes. Control layers: high-level fuzzy AAN controller and a lower-level PID torque controller on the motor driver. Evaluation: EMG recordings from Vastus Lateralis, Semimembranosus, and Hamstrings; IRMS, standard deviation, and a relative performance index. Solution and implementation 1. Convert movement quality into a Strength Index The controller represents the user\u0026rsquo;s instantaneous ability with a scalar I_s in the range 0 to 1. The assistance policy is:\nassistive torque = desired torque * (1 - I_s) When the measured motion and torque behavior indicate that the user is keeping up with the reference, I_s increases and assistance falls. When the user lags the reference or the robot is not delivering the expected torque, I_s decreases and the controller provides more help.\nThe fuzzy system uses three inputs:\nknee angular-velocity error; hip angular-velocity error; and the difference between desired and assistive torque. Each input is mapped to Negative, Zero, or Positive fuzzy sets. The output uses five assistance/strength bands. A nine-rule Mamdani inference system combines the inputs; rule firing uses the minimum membership value and the final crisp index uses centroid defuzzification. This gives the controller a compact rule base instead of a large learned model or a continuous EMG classifier.\n2. Track a normal STS trajectory without hard-coding one user\u0026rsquo;s motion The desired hip and knee velocity profiles are sixth-degree polynomials fitted to 20 normal STS transfer shapes from able-bodied data. A normalized knee torque-angle profile supplies the full-assistance reference. The fuzzy index scales that reference rather than replacing it, so the controller retains a consistent movement target while changing the amount of help.\n3. Trigger assistance from the STS phase The manuscript divides STS into flexion, transition, extension, and stabilization phases. Assistance starts near lift-off from the chair. The reported trigger criterion uses the combination of stable knee motion and the hip velocity/acceleration pattern observed immediately before lift-off; analysis of 20 STS transfers was used to identify this event.\nThe four STS phases and the reported trigger point near chair lift-off.\n4. Run the loop on the robot The runtime architecture separates four functional responsibilities:\nCAN sensor data | v filter joint velocity and torque signals | v compute motion/torque errors | v fuzzy Strength Index -\u0026gt; scale desired torque | v motor-driver PID -\u0026gt; CAN -\u0026gt; knee BLDC actuators | v log sensor, motor, and controller data The implementation source contains a Python fuzzy controller and C++ ROS2 nodes for CAN reading and motor commands. Its real-time filters are second-order Butterworth filters configured with a 400 Hz sampling assumption: 5 Hz for hip velocity and 10 Hz for knee velocity and torque feedback. That configuration is an implementation detail, not a claim that every end-to-end path was measured at 400 Hz.\nFunctional ROS2 architecture used for sensor acquisition, fuzzy control, motor commands, and logging.\nExperimental design The reported evaluation used four healthy subjects, a 46 cm chair, and three target speeds:\nslow: 20 deg/s; normal: 35 deg/s; fast: 60 deg/s. Each subject completed three conditions:\nNo Exo: baseline STS without the device. Exo Without Torque: the device was worn but delivered no assistive torque. Exo With Torque: the AAN controller was enabled with the 50% assistance setting. The primary analysis used EMG IRMS as a measure of aggregate muscle effort and signal standard deviation as a variability measure. The manuscript defines the performance index as the percentage change from the No Exo baseline; positive values mean lower measured effort and negative values mean higher effort.\nResults and impact The following values are the manuscript\u0026rsquo;s averages across the four subjects. They are percentage changes relative to No Exo, not clinical effect sizes.\nCondition Speed IRMS change SD change Exo With Torque Slow 30.34% reduction 33.81% reduction Exo With Torque Normal 13.20% reduction 16.45% reduction Exo With Torque Fast 7.59% reduction 14.10% reduction Exo Without Torque Slow 41.21% increase 30.09% increase Exo Without Torque Normal 38.70% increase 36.17% increase Exo Without Torque Fast 40.87% increase 42.53% increase The AAN torque follows the desired profile shape at a lower magnitude across slow, fast, and normal STS speeds.\nThe main product and engineering conclusions are:\nthe assistance setting reduced measured effort at all three tested speeds; the largest average reduction occurred at slow speed, where assistance is most relevant to users who cannot generate the reference motion easily; the benefit weakened at fast speed, so \u0026ldquo;adaptive\u0026rdquo; does not mean equally effective in every movement regime; the passive mechanical load was large enough to increase effort when torque was disabled, making the no-torque control condition essential; the torque trace behaved as intended qualitatively, but the supplied manuscript does not report latency, confidence intervals, statistical significance, actuator safety margins, or long-term reliability. Processed Vastus Lateralis EMG examples for the nine speed/condition combinations reported in the manuscript.\nScope limitation: the experiment involved four healthy subjects. The paper uses labels such as \u0026ldquo;low-strength\u0026rdquo; and \u0026ldquo;moderate-strength\u0026rdquo; for controller output categories, but the tested group was not a clinical cohort of elderly, post-stroke, or mobility-impaired participants. The results should therefore be presented as an engineering prototype evaluation, not as proof of rehabilitation efficacy.\nKey learnings and takeaways Assistance is a control policy, not a constant torque value. Estimating the user\u0026rsquo;s current tracking ability makes the same hardware useful across different movement capabilities. The mechanical baseline matters. A wearable robot can increase effort before its controller helps; product evaluation must isolate the device burden from the controller benefit. Trigger timing is a product requirement. A correct torque magnitude delivered at the wrong STS phase is still a poor user experience and can destabilize the movement. Low-power deployment changes the design. A compact fuzzy rule base, filtered kinematic signals, and a Raspberry Pi/ROS2 stack are practical when compute, sensing, and wiring are constrained. The next validation step is not another plot from the same cohort. The project needs larger and more diverse participants, comfort and safety measures, latency and repeatability data, and longer-term evaluation before making rehabilitation or clinical claims. Visuals to add next The supplied manuscript provides the architecture, trigger, torque, and EMG figures embedded above. A stronger public case study would add:\na short, consented video showing the three experimental conditions; a system-level timing diagram with sensor-to-actuator latency and fault handling; an anonymized aggregate results plot with uncertainty intervals and per-subject points; a public repository or reproducible package, if the team decides to release one. No public source-code, demo-video, or acceptance link was present in the supplied project files, so none is fabricated here.\nPublication and project status The available package contains a manuscript and cover letter dated August 2025 that were prepared for submission to Robotics and Autonomous Systems. It does not contain evidence of acceptance, publication, or a public DOI. The October 2023 start date reflects the earliest dated project report found, not a formal project kickoff. The inspected implementation files also include experiment-specific constants, so this page describes a working research prototype rather than claiming production-release maturity.\n","permalink":"https://mahdisf.github.io/projects/fuzzy-aan-knee-exoskeleton/","summary":"A fuzzy Strength Index adapts knee-exoskeleton torque during sit-to-stand transitions, combining low-power ROS2 software, CAN motor control, and EMG-based engineering evaluation.","title":"Fuzzy Assist-as-Needed Control for the FUM-NEXA Knee Exoskeleton"},{"content":"Today I tested the ROS2 planning stack in Gazebo with a simulated manipulator. The robot completed the pick-and-place behavior, but the controller still needs a tighter feedback loop for fine-grained placement.\nAdded a new lifecycle node for state management. Logged delay spikes from the joint trajectory action. Verified collision boundaries in the simulator. This content is part of the Logs section and will not appear in the blog post list.\n","permalink":"https://mahdisf.github.io/logs/robotics-simulation-log/","summary":"A short log entry covering ROS2 simulation updates and system observations.","title":"ROS2 Simulation and System Log"},{"content":"An experimental project translating natural-language commands into ROS2 task plans for a simulated manipulator. It combines prompt engineering, symbolic planning, and ROS2 action clients to execute autonomous task sequences.\n","permalink":"https://mahdisf.github.io/projects/llm-powered-robotic-task-planning/","summary":"Robotic task planning using language models and ROS2 execution.","title":"LLM-Powered Robotic Task Planning"},{"content":"A real-time human follower robot that uses vision processing and ROS2 navigation. The system integrates camera-based pose estimation with motion control and safety checks for responsive tracking in dynamic indoor environments.\n","permalink":"https://mahdisf.github.io/projects/human-follower-mobile-robot/","summary":"Vision-based human follower robot built with ROS2 and embedded control.","title":"Human Follower Mobile Robot"},{"content":" Download CV I am a robotics software engineer and technical product manager with more than four years of experience across quadruped autonomy, rehabilitation exoskeletons, robot simulation, embedded control, and agentic systems. I work across the engineering and product layers: from ROS2 architecture and robot integration to customer discovery, requirements, prioritization, and MVP delivery.\nAt LabCD.ai, I moved from Robotics Software Engineer to Technical Product Manager in February 2026. I helped take AgenticControl, a multi-agent framework for control-system design, from concept to MVP; conducted more than 100 customer interviews; defined product requirements and system architecture; and coordinated seven engineers and three stakeholders.\nAlongside my product work, I am completing an M.Sc. in Mechatronics Engineering at Iran University of Science and Technology. My research focuses on risk-aware quadruped navigation using deep reinforcement learning, Isaac Gym, Dijkstra planning, and MPPI. The reported framework trained across 12,000 parallel environments, reached 94.2% success on unseen maps, and reduced simulated collisions by 71.4% relative to monolithic baselines.\nWhat I Work On ROS2 robotic software in Python and C++, including sensor, actuator, control, and motion-planning pipelines. Robot learning, reinforcement learning, perception, and risk-aware autonomy. Simulation-to-real and hardware-in-the-loop workflows with Isaac Gym/Sim, Gazebo, RViz, and MoveIt. Product vision, MRD/PRD authoring, customer discovery, roadmapping, and MVP scoping. Cross-functional delivery across robotics, control, AI, software, and business teams. Selected Experience Technical Product Manager\nLabCD.ai, Feb 2026 - Present\nAuthored the founding MRD, business plan, and business canvas for an agentic-AI startup. Turned market research, competitive analysis, and 100+ customer interviews into product requirements and a prioritized roadmap. Defined the architecture and validation logic for AgenticControl and helped advance it from concept to MVP. Coordinated seven engineers and three stakeholders across AI, control, software, and business. Robotics Software Engineer\nLabCD.ai, Nov 2025 - Feb 2026\nDesigned an agent workflow for trimming, state-space realization, controller generation, and closed-loop simulation. Built topology parsing and signal-interconnection logic and integrated numerical solving, linearization, stability, and frequency-domain analysis. Researcher and Robotic Software Engineer\nIUST AI and Dynamic Systems Research Lab, Nov 2024 - Present\nDesigned requirements, evaluation criteria, and reinforcement-learning components for hierarchical quadruped navigation. Orchestrated 12,000 Isaac Gym environments and combined global Dijkstra planning with 256,000 concurrent MPPI trajectories. Contributed to ROS2/RViz sim-to-real integration for a 5-DOF robotic arm. Technical and Product Manager\nDiginext Startup Camp, Aug 2025 - Nov 2025\nDefined the vision, requirements, roadmap, and technical architecture for an LLM-powered video-editing product. Built an internal MVP prototype through five-week Agile sprints; the project paused before external user testing or launch. Robotic Software Engineer\nFUM Center of Advanced Rehabilitation and Robotics Research, Feb 2022 - Jan 2024\nBuilt modular ROS2 C++/Python stacks for exoskeleton sensing, motor control, calibration, and real-time assistive torque. Served as project manager and main author for a fuzzy assist-as-needed knee-exoskeleton controller running at 250 Hz. Integrated and calibrated sensors, motors, Raspberry Pi control boards, and communication interfaces. Education M.Sc. Mechatronics Engineering\nIran University of Science and Technology, 2024 - 2026\nThesis: Risk-aware path planning and control for a quadruped robot under interaction uncertainty using deep reinforcement learning, Isaac Gym, and MPC/MPPI.\nBronze Medalist, 2025 Talent Development Award, Department of Mechanical Engineering.\nDiploma in Product Management\nAlison Academy, 2023 - 2024\nProduct lifecycle management, Agile/Scrum, UX and design thinking, market research, experimentation, and data-driven strategy.\nB.Sc. Mechanical Engineering\nFerdowsi University of Mashhad, Sep 2018 - Feb 2024\nProject: Design, simulation, and implementation of a real-time fuzzy control system for a knee exoskeleton robot using MATLAB, C++, Python, ROS2, and Raspberry Pi.\nAwarded Best Technologist Student of 2023 by the Department of Mechanical Engineering.\nCore Capabilities Robotics software: ROS2, Python, C++, RViz, MoveIt, Gazebo, sensor and actuator integration.\nSimulation and control: Isaac Gym/Sim, MATLAB/Simulink, Simscape Multibody, reinforcement learning, MPC/MPPI, fuzzy and PID control, sim-to-real, hardware-in-the-loop.\nAI and perception: Deep reinforcement learning, LLM/VLM and multi-agent systems, OpenCV, YOLO, Depth Anything V2, Kalman filtering.\nProduct and delivery: Product strategy, MRD/PRD, customer discovery, roadmapping, prioritization, Agile/Scrum, MVP development, and stakeholder coordination.\nEngineering tools and hardware: Git, Docker, Linux, MATLAB, Raspberry Pi, Arduino, ESP32, motor controllers, IMUs, encoders, and PLC systems.\n","permalink":"https://mahdisf.github.io/about/","summary":"\u003cdiv class=\"cv-download-wrap\"\u003e\n  \u003ca href=\"/cv.pdf\" class=\"cv-download-btn\" download\u003e\n    \u003csvg xmlns=\"http://www.w3.org/2000/svg\" width=\"16\" height=\"16\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"\u003e\u003cpath d=\"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4\"/\u003e\u003cpolyline points=\"7 10 12 15 17 10\"/\u003e\u003cline x1=\"12\" y1=\"15\" x2=\"12\" y2=\"3\"/\u003e\u003c/svg\u003e\n    Download CV\n  \u003c/a\u003e\n\u003c/div\u003e\n\u003cp\u003eI am a robotics software engineer and technical product manager with more than four years of experience across quadruped autonomy, rehabilitation exoskeletons, robot simulation, embedded control, and agentic systems. I work across the engineering and product layers: from ROS2 architecture and robot integration to customer discovery, requirements, prioritization, and MVP delivery.\u003c/p\u003e","title":"About"},{"content":"For robotics software, autonomous-systems research, or technical product opportunities, the best way to reach me is by email.\nEmail: Mahdi_Sarfarazi@outlook.com LinkedIn: linkedin.com/in/sarfarazi GitHub: github.com/mahdisf I am especially interested in work that combines robotics software and product ownership: ROS2 systems, simulation-to-hardware workflows, robot learning and control, AI-assisted engineering products, and technical product management for robotics or autonomous systems.\n","permalink":"https://mahdisf.github.io/contact/","summary":"\u003cp\u003eFor robotics software, autonomous-systems research, or technical product opportunities, the best way to reach me is by email.\u003c/p\u003e\n\u003cul\u003e\n\u003cli\u003eEmail: \u003ca href=\"mailto:Mahdi_Sarfarazi@outlook.com\"\u003eMahdi_Sarfarazi@outlook.com\u003c/a\u003e\u003c/li\u003e\n\u003cli\u003eLinkedIn: \u003ca href=\"https://linkedin.com/in/sarfarazi\"\u003elinkedin.com/in/sarfarazi\u003c/a\u003e\u003c/li\u003e\n\u003cli\u003eGitHub: \u003ca href=\"https://github.com/mahdisf\"\u003egithub.com/mahdisf\u003c/a\u003e\u003c/li\u003e\n\u003c/ul\u003e\n\u003cp\u003eI am especially interested in work that combines robotics software and product ownership: ROS2 systems, simulation-to-hardware workflows, robot learning and control, AI-assisted engineering products, and technical product management for robotics or autonomous systems.\u003c/p\u003e","title":"Contact"},{"content":"","permalink":"https://mahdisf.github.io/now/","summary":"","title":"Now"}]