第130章 Dynamic Object Relation
动态对象关系
第129章建立了:
Object A
↓
Relation
↓
Object B
但现实世界中的 Relation 几乎从来不是永久不变的。
例如:
Hand
↓
Far
↓
Egg
经过一段时间:
Hand
↓
Approaching
↓
Egg
然后:
Hand
↓
Contact
↓
Egg
随后:
Hand
↓
Holding
↓
Egg
最后:
Hand
↓
Leaving
↓
Egg
因此,本章研究的核心问题是:
机器如何在连续时间中发现、维护、更新和终止 Object Relation?
130.1 Relation 不再是静态事实
传统的关系表达:
Near(A,B)
只告诉机器:
A 与 B 很近
但是现实认知需要知道:
什么时候近?
近了多久?
之前是什么关系?
正在变近还是变远?
关系是否正在增强?
关系是否即将消失?
因此应该建立:
Relation(t)
例如:
R(t1) = Far
R(t2) = Approaching
R(t3) = Near
R(t4) = Contact
R(t5) = Leaving
于是 Relation 不再是:
R
而成为:
R(t)
即:
随时间变化的认知关系。
130.2 Dynamic Relation 的定义
可以定义:
Dynamic Object Relation 是两个或多个 Cognitive Object 之间,其类型、状态、强度、方向或有效性能够随时间发生变化的认知关系。
基本结构:
DynamicRelation
{
source,
type,
target,
state,
value,
timestamp
}
进一步:
DynamicRelation
{
source,
type,
target,
state,
value,
start_time,
update_time,
confidence,
history
}
例如:
Hand
↓
Approaching
↓
Egg
不仅记录:
Approaching = TRUE
还记录:
Distance = 20cm
RelativeVelocity = -0.8m/s
StartTime = T100
Confidence = 0.94
130.3 Relation 的时间连续性
Dynamic Relation 最重要的特征是:
Current Relation
不是孤立产生的。
它来自:
Previous Relation
+
Current Perception
+
Temporal Change
即:
R(t)
=
f(
R(t-1),
Perception(t),
ObjectState(t)
)
例如:
t1:
Far
t2:
Far + Distance Decreasing
t3:
Approaching
t4:
Near
t5:
Contact
机器因此能够理解:
不是“突然 Contact”,而是“从远处逐渐接近,然后发生接触”。
这就是时间连续认知。
130.4 Relation Lifecycle
一个 Dynamic Relation 应该具有生命周期:
Unknown
↓
Detected
↓
Confirmed
↓
Active
↓
Updated
↓
Inactive
↓
Ended
例如:
Hand
↓
Contact
↓
Egg
开始时:
Unknown
传感器发现:
Detected
多个证据确认:
Confirmed
持续接触:
Active
压力变化:
Updated
手开始离开:
Inactive
完全分离:
Ended
因此 Relation 本身具有:
Lifecycle
130.5 Relation Created
关系首先需要能够:
Created
例如:
Distance > Threshold
时:
Near = FALSE
随着移动:
Distance < Threshold
系统产生:
Near Created
即:
Far
↓
Near
关系创建事件:
RelationCreated
因此:
Perception
↓
Condition Satisfied
↓
Relation Created
130.6 Relation Active
关系建立之后,并不意味着每一帧都重新创建。
例如:
t1 Near
t2 Near
t3 Near
t4 Near
应该理解为:
Near Relation
↓
Active
而不是:
Near Created
Near Created
Near Created
Near Created
因此系统必须区分:
Created
与:
Persisting
即:
Relation Created
↓
Relation Active
↓
Relation Continues
130.7 Relation Update
虽然关系类型没有改变:
Near
但关系内部的值可能不断变化。
例如:
Distance:
20cm
↓
15cm
↓
10cm
↓
5cm
因此:
Near
仍然是 Active。
但:
Relation Value
不断更新。
例如:
Near(A,B)
{
distance: 20cm
}
变成:
Near(A,B)
{
distance: 15cm
}
再变成:
Near(A,B)
{
distance: 10cm
}
因此:
Relation Type 可以保持不变,而 Relation State 与 Relation Value 可以持续变化。
130.8 Relation Strength
一些关系具有强度。
例如:
Near
可以从:
Weak
逐渐变成:
Strong
例如:
Distance = 50cm
可能是:
WeakNear
而:
Distance = 3cm
可能是:
StrongNear
因此:
Relation
├── Type
├── Strength
└── Value
例如:
Contact
Pressure = 0.2N
变成:
Contact
Pressure = 1.5N
Relation Type 没变:
Contact
但 Relation Strength 增强。
130.9 Relation Weakening
关系也可以减弱。
例如:
Contact
Pressure = 2.0N
逐渐:
1.0N
↓
0.5N
↓
0.1N
最终:
NoContact
于是:
StrongContact
↓
WeakContact
↓
ContactEnding
↓
NoContact
因此 Dynamic Relation 不只有:
Create
Destroy
还存在:
Strengthen
Weaken
130.10 Approaching 的动态性质
例如:
Hand
Egg
初始:
Distance = 100cm
然后:
80cm
60cm
40cm
20cm
因为:
d(Distance)/dt < 0
所以:
Approaching(Hand,Egg)
成立。
注意:
Near
和:
Approaching
并不是同一个概念。
例如:
Distance = 5cm
但手正在离开:
Distance:
3cm
↓
4cm
↓
5cm
那么:
Near = TRUE
Approaching = FALSE
Leaving = TRUE
这说明:
空间关系描述“在哪里”,动态关系描述“正在怎样变化”。
130.11 Near 与 Approaching 可以同时存在
例如:
Distance = 8cm
同时:
Distance decreasing
于是:
Near = TRUE
Approaching = TRUE
这说明 Relation 并不是互斥标签。
一个 Object Pair 可以同时具有多个关系:
Hand
├── Near → Egg
├── Approaching → Egg
└── Above → Egg
因此:
Object Pair
↓
Relation Set
而不是:
Object Pair
↓
One Relation
130.12 Relation Set
可以定义:
RelationSet(A,B)
例如:
Hand
│
├── Near
├── Above
├── Approaching
└── Facing
│
Egg
于是机器可以同时理解:
Spatial
+
Motion
+
Orientation
这与第125章:
Multivariate Perception
形成对应。
多元感知:
Position
Velocity
Orientation
Contact
Force
经过关系计算后:
Near
Approaching
Above
Contact
形成:
Multivariate Relation
130.13 Relation State
Relation 需要独立的 State。
例如:
Relation:
Contact
其状态可以是:
Pending
Active
Strengthening
Weakening
Ending
Ended
例如:
Contact
↓
Active
↓
Pressure Increasing
↓
Strengthening
↓
Pressure Decreasing
↓
Weakening
↓
Ending
↓
Ended
因此:
Relation Type
与:
Relation State
必须分离。
130.14 Relation State Machine
可以建立:
Unknown
↓
Detected
↓
Confirmed
↓
Active
├── Strengthening
├── Weakening
└── Stable
↓
Ending
↓
Ended
这与第105章的:
Cognitive State Machine
形成统一结构。
Relation 自身也成为:
Stateful Cognitive Entity
130.15 Relation History
如果机器只保存:
CurrentRelation = Contact
那么它不知道:
之前发生了什么。
所以必须保存:
Relation History
例如:
t1 Far
t2 Approaching
t3 Near
t4 Contact
t5 Holding
t6 Leaving
形成:
RelationHistory(A,B)
这使系统能够回答:
How did A and B become related?
而不仅仅是:
How are A and B related now?
130.16 Relation History 与 Event
关系历史可以直接产生事件:
Far
↓
Approaching
产生:
ApproachStarted
然后:
Approaching
↓
Contact
产生:
ContactStarted
然后:
Contact
↓
Leaving
产生:
ContactEnded
因此:
Relation History
↓
Transition Detection
↓
Event
130.17 Relation Transition
可以定义:
RelationTransition
{
old_relation,
new_relation,
timestamp
}
例如:
{
old: Approaching,
new: Contact,
timestamp: T500
}
机器因此知道:
Approaching
↓
Contact
而不是简单知道:
Contact = TRUE
这两者的认知能力完全不同。
130.18 Relation Prediction
有了:
History
+
Current State
+
Velocity
机器可以预测下一关系。
例如:
Far
↓
Approaching
↓
Near
根据:
Relative Velocity
可以预测:
Expected Contact
形成:
Current Relation
↓
Temporal Trend
↓
Future Relation
例如:
Approaching
+
Distance = 5cm
+
Relative Velocity = 1m/s
可能预测:
Contact Soon
于是:
Dynamic Relation
↓
Relation Prediction
成为决策系统的输入。
130.19 Relation 与 Object State
关系变化还可以改变对象状态。
例如:
Hand
↓ Holding
↓
Egg
可能使:
Egg.State = Held
又例如:
Egg
↓ SupportedBy
↓
Table
可能形成:
Egg.State = Supported
因此:
Relation
↓
Object State
成为一个重要认知路径。
130.20 Object State 与 Relation State 的区别
必须进一步区分:
Object State
与:
Relation State
例如:
Egg.State = Held
是 Object State。
而:
Holding(Hand,Egg).State = Active
是 Relation State。
结构:
Hand
│
│ Holding
↓
Egg
这里:
Holding
是关系。
而:
Held
是 Egg 的状态。
因此:
Relation
↓
State Evaluation
↓
Object State
形成转换。
130.21 Relation 与 Situation
多个动态关系同时变化,可以形成 Situation。
例如:
Hand ──Approaching──> Egg
Egg ──SupportedBy──> Table
Robot ──Near──> Table
随后:
Hand ──Contact──> Egg
再随后:
Hand ──Holding──> Egg
系统可以识别:
Object Interaction Situation
所以:
Dynamic Relations
↓
Relation Pattern
↓
Situation
是一个非常重要的认知层次。
130.22 Relation Pattern
单个关系:
Contact(A,B)
只表达:
A 接触 B
但关系序列:
Approaching(A,B)
↓
Contact(A,B)
↓
Holding(A,B)
↓
Leaving(A,B)
形成一个:
Relation Pattern
它可以代表:
Pick Up
类似地:
Approaching
↓
Contact
↓
Force Increasing
↓
Object Moving
可能表示:
Pushing
因此:
复杂行为可以通过 Dynamic Relation Pattern 被识别。
130.23 Relation Pattern 与行为识别
例如:
Hand
与:
Cup
之间:
Near
↓
Contact
↓
Holding
↓
Cup Position Changes
系统可以形成:
Pickup(Cup)
而:
Hand
↓
Contact
↓
Force ↑
↓
Cup Position Changes
可以形成:
Push(Cup)
因此:
Relation Sequence
↓
Behavior Recognition
不需要依赖对象名称本身。
机器可以通过:
关系变化模式
理解行为。
130.24 Relation Network 的动态变化
第129章建立了:
Object Graph
现在进一步建立:
Dynamic Object Graph
例如初始:
Hand Egg
│ │
│ │
└─ Near ─┘
随后:
Hand
│
Approaching
↓
Egg
然后:
Hand
│
Contact
↓
Egg
再:
Hand
│
Holding
↓
Egg
因此整个:
Cognitive World Graph
都在持续变化。
130.25 Dynamic Graph
可以定义:
G(t) = (O, R(t))
其中:
O = Objects
R(t) = Current Relations
那么:
G(t1)
与:
G(t2)
可能不同。
例如:
G(t1)
Hand ──Near──> Egg
而:
G(t2)
Hand ──Contact──> Egg
所以:
ΔG
代表:
Cognitive World Change
这一步非常重要。
机器不再只是理解:
World
而开始理解:
World Changing Over Time
130.26 Relation Change Detection
系统需要持续检测:
ΔRelation
例如:
R(t-1) = Near
R(t) = Contact
得到:
RelationChanged
进一步:
Old Relation
+
New Relation
形成:
Transition
因此:
Perception(t)
+
Memory(t-1)
↓
Relation Comparison
↓
Relation Change
这实际上把:
Perception
与:
Memory
连接起来。
130.27 Relation Memory
Dynamic Relation 必须进入记忆系统。
例如:
Hand
held
Egg
历史可能保存:
08:30 Approaching
08:30 Contact
08:31 Holding
08:31 Leaving
08:31 Released
于是系统不仅知道:
Egg was held
还知道:
When
How long
By whom
What happened before
What happened after
形成:
Relational Memory
130.28 Relation Duration
关系还可以具有持续时间:
Duration
例如:
Contact Start = T100
Contact End = T130
因此:
Duration = 30 units
可以区分:
Brief Contact
与:
Long Contact
类似:
Holding Duration
可以成为行为识别的重要特征。
因此:
Relation
+
Duration
可以产生更高级的认知。
130.29 Relation Frequency
不仅需要:
Duration
还可以记录:
Frequency
例如:
Contact
Contact
Contact
Contact
如果一个 Object Pair 频繁产生:
Contact
机器可以形成:
Repeated Interaction
进一步:
Repeated Relation
↓
Interaction Pattern
这为长期学习提供基础。
130.30 Relation Causality
关系变化还可能参与因果判断。
例如:
Hand
↓
Contact
↓
Egg
随后:
Force ↑
随后:
Egg Velocity ↑
随后:
Egg Position Changes
系统可能建立:
Contact
+
Force
↓
Motion
因此:
Relation
↓
Interaction
↓
Change
可以成为:
Causal Hypothesis
的基础。
130.31 Relation 与 Action
行动通常改变 Relation。
例如:
Action:
MoveHandToEgg
预期:
Far
↓
Approaching
↓
Near
↓
Contact
因此:
Action
↓
Expected Relation Change
实际感知:
Perception
↓
Actual Relation Change
两者可以比较:
Expected
vs
Actual
如果不一致:
Expected Contact
Actual Far
系统可以发现:
Action Failed
因此 Dynamic Relation 是:
Action Feedback
的重要依据。
130.32 Relation Prediction 与 Decision
进一步:
Current Relation
↓
Prediction
↓
Risk Evaluation
↓
Decision
例如:
Object
↓
Approaching
↓
Distance decreasing
↓
Collision predicted
机器可以形成:
CollisionRisk
随后:
Decision
↓
Stop
因此:
Dynamic Relation
最终可以进入:
Decision System
130.33 Dynamic Relation 的统一模型
可以建立:
DynamicRelation
{
id,
source_object,
relation_type,
target_object,
state,
strength,
value,
start_time,
update_time,
end_time,
confidence,
source,
history
}
例如:
{
id: R001,
source_object: Hand,
relation_type: "approaching",
target_object: Egg,
state: "active",
strength: 0.82,
value: {
distance: 15cm,
relative_velocity: 0.8m/s
},
start_time: T100,
update_time: T110,
confidence: 0.96,
source: "perception_engine"
}
130.34 Dynamic Relation 的核心数据流
最终形成:
Perception
↓
Object Attributes
↓
Attribute Comparison
↓
Relation Detection
↓
Relation State
↓
Relation Update
↓
Relation History
↓
Relation Transition
↓
Event
↓
Situation
↓
Prediction
↓
Decision
这是:
Dynamic Object Relation
的完整认知链。
130.35 本章核心架构
Cognitive World
│
Dynamic Object Graph
│
┌────────────┼────────────┐
↓ ↓ ↓
Object A Relation Object B
│
┌──────────┼──────────┐
↓ ↓ ↓
Type State Strength
│ │ │
Near Active 0.8
Contact Changing 0.6
Holding Ending 0.9
时间维度:
R(t1)
↓
R(t2)
↓
R(t3)
↓
R(t4)
关系生命周期:
Unknown
↓
Detected
↓
Confirmed
↓
Active
↓
Strengthening / Weakening
↓
Ending
↓
Ended
关系变化:
Far
↓
Approaching
↓
Near
↓
Contact
↓
Holding
↓
Leaving
↓
Far
130.36 本章核心定义
Dynamic Object Relation 是 Cognitive Object 之间随时间持续变化的关系结构。它不仅表示两个对象当前存在什么关系,还表示关系何时建立、如何变化、变化强度、持续时间以及何时结束。
因此:
Static Relation
=
R(A,B)
升级为:
Dynamic Relation
=
R(A,B,t)
进一步:
R(A,B,t)
=
Type
+
State
+
Strength
+
Value
+
Time
+
Confidence
+
History
最终形成:
Object
↓
Attribute
↓
Relation
↓
Dynamic Relation
↓
Relation Transition
↓
Event
↓
Situation
↓
Behavior
↓
Prediction
↓
Decision
这意味着 WSaiOS-ICAI 的世界模型已经从:
Object
+
Static Relation
进入:
Objects
+
Relations
+
Time
+
Change
即:
Cognitive World
=
Dynamic Object-Relation Network
机器不再只是知道“谁和谁有什么关系”,而开始知道“这种关系正在如何发生”。
而当多个 Dynamic Relation 在同一时间窗口内共同变化时,系统面对的就不再是单个 Relation,而是:
Relation A
+
Relation B
+
Relation C
+
Temporal Pattern
这自然进入下一层:
第131章 Relation Pattern
核心问题:
机器如何从多个对象关系及其连续变化中识别一个具有意义的关系模式?
例如:
Hand → Approaching → Egg
Egg → SupportedBy → Table
Hand → Contact → Egg
Hand → Holding → Egg
Egg → Leaving → Table
这些关系单独看只是 Relation。
组合起来,却可能代表:
Pick Up Egg
这将把:
Dynamic Relation
进一步提升为:
Relation Pattern
并开始进入 行为认知与事件认知。