Loading [MathJax]/jax/output/HTML-CSS/jax.js

Friday, October 25, 2024

A Modest Proposal: Statistical Token Prediction Is No Replacement for Syntactic Construction

A Modest Proposal: Statistical Token Prediction Is No Replacement for Syntactic Construction

by Stephen Crowley

October 25, 2024

1Current Generative-Pretrained-Transformer Architecture

Given vocabulary V, |V|=v, current models map token sequences to vectors:

(t1,,tn)XRn×d

Through layers of transformations:

softmax(QKT/d)V

where Q=XWQ, K=XWK, V=XWV

Optimizing:

maxθlogP(tn+1|t1,,tn;θ)

2Required Reformulation

Instead, construct Abstract Syntax Trees where each node η must satisfy:

η{Noun,Verb,Adjective,Conjunction,}

With composition rules R such that for nodes η1,η2:

R(η1,η2)={valid\_subtreeif grammatically validotherwise

And logical constraints L such that for any subtree T:

L(T)={Tif logically consistentif contradictory

3Parsing and Generation

Input text s maps to valid AST T or error E:

parse(s)={Tif valid ASTE(closest\_valid,violation)otherwise

Generation must traverse only valid AST constructions:

generate(c)={T|R(T)L(T)}

where c is the context/prompt.

4Why Current GPT Fails

The statistical model:

softmax(QKT/d)V

Has no inherent conception of:

  • Syntactic validity

  • Logical consistency

  • Conceptual preservation

It merely maximizes:

P(tn+1|t1,,tn)

Based on training patterns, with no guaranteed constraints on:

ni=1P(ti|t1,,ti1)

This allows generation of:

  • Grammatically invalid sequences

  • Logically contradictory statements

  • Conceptually inconsistent responses

5Conclusion

The fundamental flaw is attempting to learn syntax and logic from data rather than building them into the architecture. An AST-based approach with formal grammar rules and logical constraints must replace unconstrained statistical token prediction.

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.

The Devil’s Dice: How Chance and Determinism Seduce the Universe

The Devil’s Dice: How Chance and Determinism Seduce the Universe The Devil’s Dice: How Chance and Determini...