Saturday, July 25, 2026

Problems with Installing Jackpack on Jetson Orin Nano on Windows 11

 Trying to install Ubuntu on Jetson Orin Nano Super Development Kit can be problematic. There are several key issues. 

There are several main ways to install Jetpack an Ubuntu to your board. You need to download the Jetpack 7.2 install files from Nvidia's website: 

https://developer.nvidia.com/embedded/jetpack/downloads



You can download either the SDK manager or the Jetpack ISO image. Download the ISO image on your PC. Then you need a micro SD card that is at least 64GB. Download the app Balena Etcher to flash the image from your PC to your Micro SD card. Then you can insert your card into the Micro SD card slot that is hiding underneath the CPU board and it cooing fan. Connect your power cable to the board. Then keep pressing the esc button intermittenly until the boot manger shows up. Select Boot Manager, then choose SD card. We will not go into details here.

The second method is to download the SDK manager from the Nvidia website instead. This is an easier way cause it gives you automatic connection and other checks to see if there is anything missing or the connection is not created. 


A common problem is that your SDK manager is unable to detect your Jetson board. 1. You need to put your Jetson Orin Nano board in the Force Recovery Mode. To do that you must find the fc_esc pin. There are two main regions on the board that have pins. Some will suggest that you use a jumper to connect pin 9 and pin 10. But that will not work if you board has no pin 9. For a newer Jetson board, you have a pin called fc_esc. My fc_esc pin hides underneath the CPU/cooling fan circuit and it took me a lot of time to find it. You need to connect the fc_esc pin to a GND pin, which is often found next to it, using a jumper.


2. Another problem is the Jetpack 7.2 requires your Windows 11 to have the APX driver for the sytem to be able to detect the board. The easiest way is to download this app called Zadig. When it is run, it will automatically detect the new drivers that you system need to run any connected devices. Here is the webstie:

https://zadig.akeo.ie/

3. If you finally have your SDK manager being able to detect your Jetson Orin Nano board, the final obstacle is your usb connect. The manager will flash the automatically downloaded image to your Jetson board. You need to connect your Jetson's usb c port to your PC. You need a usb data wire that is fast enough. If the usb cable that you use is either not for data transfer or it is too slow, the SDK manager will complain. Use a good usb cable for this purpose. 

If everything works out, your flashing and installation will be completed by the SDK manager automatically. You will get your first ubuntu screen on the monitor that is connected to your Jetson board. The last problem is the Jetson board does not have an HDMI socket. The Jetson board comes with the Display Port (DP) instead. So, you should have purchase a DP to HDMI adapter before you flash your Jetpack to your board. If you have already connected your board to a monitor you will see this: 


Wednesday, June 24, 2026

How not To Trust an LLM?

 

As impressive as Large Language Models (LLMs) have become, one fundamental reality remains: they are not deterministic systems. Their outputs are built from a chaotic blend of training data, fine-tuning, context windows, and billions of opaque parameters. Even the engineers who build these models cannot fully explain why a specific output appears when it does.

Despite this, modern AI architectures often hand LLMs the keys to the kingdom. The current industry standard typically looks like this:

frontend → LLM → tool use

In this flow, the model acts as the brain: it interprets the user's goal, decides which tool to call, generates the necessary parameters, and effectively acts as the system’s primary decision-maker.

From an engineering perspective, this is a flawed premise. We are asking a probabilistic engine to make deterministic choices—often involving file systems, sensitive data, or critical infrastructure. That isn't just risky; it’s a failure of architectural design.

There is a more robust way to build these systems: treat the LLM as a contributor, not a commander.


A Deterministic Alternative

frontend → LLM → router → MCP server

In a secure architecture, the LLM’s role is stripped back to what it actually does well: producing structured text. Instead of granting the model permission to execute commands, it is restricted to emitting a simple, inert JSON object:

        {

              "action": "savefile", 

              "filename": "notes.txt" 

        }

This output is not "intelligence"—it is data. It is not executed; it is not trusted. It is simply passed to a deterministic backend for verification.

The Router

Think of the router as a lightweight gatekeeper. It performs one task: reading the action field and forwarding the request to the corresponding Model Context Protocol (MCP) server. It does not "interpret intent" or guess at user meaning. If the JSON structure is malformed, missing required fields, or syntactically incorrect, the router terminates the process immediately.

The MCP Server

This is where true decision-making occurs. Each MCP server is a hard-coded, sandboxed executor designed for a single category of action. It validates the JSON, checks file system boundaries, enforces security policies, and rejects anything outside its predefined scope. If the LLM tries to access a restricted directory or perform an unauthorized operation, the MCP server simply refuses.

We can turn invalid requests into a security asset:

  • Silently log them for auditing.
  • Return a clean, standardized error to the frontend.
  • In this model, the LLM never has the opportunity to bypass safety filters or cause unintended harm.


Why This Architecture Works?

This approach succeeds because it shifts the paradigm: LLMs are workers, not decision-makers.

  • Constraint: The LLM generates text and nothing else.
  • Determinism: The router dispatches requests via rigid, predictable logic.
  • Enforcement: MCP servers maintain human-defined, hard-coded boundaries.
  • Isolation: Every action is sandboxed.

By handling edge cases explicitly, we eliminate the risks that plague the older "LLM-as-decision-maker" model. No hallucination can break the system, no prompt injection can escalate privileges, and no LLM output can directly touch the underlying operating environment.

The previous paradigm relied on the assumption that a model could reliably choose safe actions. That assumption has never been true—and given the nature of current architecture, it never will be.


The Bottom Line

If you want to build a truly robust AI system, stop asking the LLM to think like a security auditor or an operating system. Ask it to do what it is optimized for: producing structured data. Then, let deterministic, human-designed components decide the execution path.

It isn't about being cynical or "distrusting" AI. It is about building systems that simply don't require you to trust them in the first place.




How Smart Are Small "Large Language Models" (LLMs) or SLM?

Copilot and I created a new text processing and char submatrix extracting script language using Free Pascal. I uploaded the user manual created by Copilot to a small LLM, Qwen 30B A3B. I ask this small LLM to write a Hello World program using this new language and it just did it correctly even though it only read the user manual once and was not fine tuned using the manual or any same scripts. 

LLMs do not have human intelligence, at least not yet. But they are extremely good at recognizing new patterns and applying pattern logic that it learned from its old training data to the new patterns. LLMs are pattern recognizing and pattern retrieval machines that retrieve patterns (including code generation) based on fine tuning. There is no major or real intelligence involved. It is all about training data, fine tuning, pattern recognition, and pattern retrieval. 

AI haters who think that LLM relies on stealing ideas to create images, music, or codes know nothing about LLM or any generative or non-generative AI that is based on the neural network algorithms. 



Saturday, June 20, 2026

Intel and AMD's ACE CPU Extensions

 Intel and AMD finally realize that the CPU needs to do matrix algebra. They created ACE CPU extensions, a set of CPU instructions for doing matrix computing in the CPU.

The real problem of the CPU is the #C pointer logic which does not look at memory as chunks like arrays, instead it treats memory as addresses that are pointed at one at a time. Fortran has always been faster than C in doing matrix computing, despite the fact that most operating systems are written in C or C pointer logic. A programming language, no matter how efficient it is in doing matrix computation, will have to either go through a C ABI or to write system call or to talk to the kernel (which is also written in C) in order to talk to the hardware.

In the era of AI, this C pointer ghost will haunt all devices making them slow in doing AI inferencing. The reason is simple, even if you don't use a C-like language to train or fine-tune AI and even if your choose a programming language that has no C-pointer logic in it, your hardware design and drivers, your OS, most available APIs and libraries, .. are all written in or built around C.



Finetuning tinyBERT with 4.4M parameters

Copilot and I successfully did our first finetuning exercise on tinyBERT, an old transformer model with only 4.4M parameters.

We are training it to recognize data structures and to convert one structure, say S-expression format, to another, say JSON. It doesn't need to even speak English. All it needs to do is to see the field name/key and values of two different data structures. We can write a backend server and wire its output to a backend for further processing. The next finetuning attempt will be to let tinyBERT extract some key data from emails.

(person (name "Alice") (age "42") (city "Tokyo") (country "Japan")) || { "name": [MASK], "age": "42", "city": "Tokyo", "country": "Japan" } (person (name "Alice") (age "42") (city "Tokyo") (country "Japan")) || { "name": "Alice", "age": [MASK], "city": "Tokyo", "country": "Japan" } (person (name "Alice") (age "42") (city "Tokyo") (country "Japan")) || { "name": "Alice", "age": "42", "city": [MASK], "country": "Japan" } ...

In the future, humans no longer need SQL queries to retrieve any information. You only need a small LLM worker that can recognize patterns.













Friday, June 19, 2026

The Problem of Gradient Descent as First Order Taylor's Approximation



Arthur Hau and Gemini 2.0
May 2, 2025

Taylor's Theorem has been invoked in a lot of real world applications as a basis for applying first-order or higher order Taylor series approximation to functions using a polynomial. 


Suppose there is a well behaved function \(f\) such that its derivatives \(f^{i}\) exists for all \(i = 1, \ldots, n\). Roughly, Taylor's Theorem states that there exists \(c \in (a, x)\) such that \[ f(x) = f(a) + f'(a) (x-a) + (1/2) f''(a) (x-a)^2 + \ldots + \frac{1}{n !} f^n (c) (x - a)^n, \label{eq:1} \] In the simplest first-order approximation case, we have 
 \[ f(x) = f(a) + f'(a) (x-a) + (1/2) f''(c) (x-a)^2. (1) \]
where \(\frac{1}{n !} f^n (c) (x - a)^n\) is often called the error of approximation.

How should we interpret equation (1). For this equation to be a good approximation first we need to check the signs of the first and the second derivative of \(f\). Since we have arbitrarily chosen \(a < x\), for \(f(a) + f'(a) (x-a)\) to be a good approximation of \(f(b)\), we need to check the signs of both \(f'(a)\) and \(f''(a)\). We have several cases to consider given \(x-a > 0\),


Case 1 \(f'(\eta) > 0\) and \(f''(\eta) > 0\) for all \(\eta \in [a,x]\).


Since \(a < x\), adding \(f'(a) (x-a)\) to \(f(a)\) results in an increase in the approximated value of \(f(x)\) which will be a good approximation if \(f(x) < f(a)\) which is true only if

\(f''>0\).


Case 2 \(f'(\eta) < 0\) and \(f''(\eta) > 0\) for all \(\eta \in [a,x]\).


This is the case in which the first order Taylor series is a bad approximation. Adding \(f'(a) (x-a)\) to \(f(a)\) results in a decrease in the approximated value of \(f(x)\), namely \(f(a)\), which give a worse approximation because \(f(x) > f(a)\) given \(f''> 0\). Reducing the approximated value from \(f(a)\) downward is unwise.



Case 3 \(f'(\eta) > 0\) and \(f''(\eta) < 0\) for all \(\eta \in [a,x]\).


\(a < x\) implies that adding adding \(f'(a) (x-a)\) to \(f(a)\) increases the approximately value of \(f(x)\).

\(a<x\), \(f'>0\), and \(f'<0'\) imply that \(f(x) > f(a)\). So, the increase in the approximated value improves upon the original approximated value \(f(a)\).


Case 4 \(f'(\eta) < 0\) and \(f''(\eta) < 0\) for all \(\eta \in [a,x]\).


I will leave this as an exercise to the reader.


In the case of \(f(x)=1/x\), \(f'(x) = -1/x^2\) which is negative for all \(x>0\) and positive for \(x<0\). On the other hand, \(f''(x) = 2/x^3\) which is positive for all \(x\).


Let's start by taking a look at this statement. Most proofs of Taylor's Theorem rely on a declaration of a statement similar to the following for any arbitrary \(n\):

\[ F(x,n) = f(b) - f(x) - f'(x) (b-x) - \frac{f''(x)}{2!} (b-x^2) - \ldots - \frac{f^{n-1}(x)}{(n-1!)}(b-x)^{n-1}.  (2)\]


What's wrong with this seemingly innocent statement? Let's rewrite this as a sequence.

\[ S_n = F(x,n) - f(b) + f(x) + f'(x) (b-x) + \frac{f''(x)}{2!} (b-x^2) + \ldots + \frac{f^{n-1}(x)}{(n-1!)}(b-x)^{n-1}. (3) \]

Does the sequence \(S_n\) converge or diverge? Why is this important? It is important because in mathematical induction, we need to assume that a statement like (2) holds for any "arbitrary" \(n\). Whether (2) holds for any arbitrary \(n\) depends on whether \(S_n\) is a convergent or a divergent sequence given in (3).


It is well known that in the case of \(f(x)=1/x\), Taylor series expansion gives

\[ f(x) = \frac{1}{x}= \frac{1}{b} - \frac{(x-b)}{b^2} + \frac{(x-b)^2}{b^3} - \frac{(x-b)^3}{b^4} + \cdots = \sum_{n=0}^{\infty} \frac{(-1)^n}{b^{n+1}} (x-b)^n . \]


Let's rewrite it in the form of (2) and we have

\[ F(x,n) = \frac{1}{b} - \sum_{i=n-1}^{\infty} \frac{(-1)^i}{b^{i+1}} (x-b)^i \label{eq:7} \]

In our sequence notation, (3) becomes

\[ S_n = F(x,n) - \frac{1}{b} + \sum_{i = n -1}^{\infty} \frac{(-1)^i}{b^{i+1}} (x-b)^i \label{eq:8} \]

Now, it is obvious that the declaration of (2) is equivalent to saying that \(S_n = 0\) which is obviously absurd. And it is now well known that the Taylor series expansion of most functions that contains quotients of polynomials do not converge. It should now be clear that the reason being Taylor ignored the signs of \(f'\) and \(f''\) when he used his series as an approximation of \(f\). For many \(f\)'s, the Taylor series which involve only polynomials give rise to bad approximate regardless of whether it is high or low order.


Conclusion


Taylor created an approximation formula of any function \(f\) consisting of a polynomial of order \(n\)

which is called the Taylor series. This series is commonly acknowledged to be highly useful in many

real world applications. However, by ignoring the second and higher derivatives of a function \(f\),

even the first-order Taylor series approximation can be misleading. If we somehow use our knowledge of the second derivative of the function, we can change the sign of the first-order term and come up with a better approximation. This is exactly what computer simulations do. Instead of setting a large step using \(x-a\) for the first-order term. A computer will use a small step \(h\). In case the sign is wrong, the computer will take the next step in the opposite direction. If instead the computer has computed the sign of \(f''\), the sign of \(h\) will be set correctly even in the first iteration.



You Do Not Need A Large Language Model (LLM) To Be 100% Accurate


Some people are sick of LLM hallucination. Most people think that LLM needs to be 100% accurate all time. But neither of these people use LLM correctly. 

LLM is just like any books or any websites or Wikipedia. No one should trust Wikipedia or even an encyclopedia100%. Anyone believes that any sources of information can be and should be 100% accurate is just unrealistic. 

You do not need LLM, large or small, to be completely accurate and you can still make great use of them. Here is an agentic AI design that can make use of any LLM with imperfect accurate. Yet your computer and your data will be almost completely protected.