main
reng 2 weeks ago
parent b4ae96b969
commit c3501c1028
  1. 2
      Assets/Qdrant/storage/collections/data-v1/0/newest_clocks.json
  2. 2
      Assets/Qdrant/storage/collections/data-v2/0/newest_clocks.json
  3. 2
      Assets/Qdrant/storage/collections/data-v3/0/newest_clocks.json
  4. 2
      Assets/Qdrant/storage/collections/keywords_v1/0/newest_clocks.json
  5. 18
      v2/app/public/keywords.json
  6. 21
      v2/app/src/components/graph.jsx

@ -1 +1 @@
{"clocks":[{"peer_id":2200039024721645,"clock_id":4,"current_tick":3,"token":3225682797052271524},{"peer_id":2200039024721645,"clock_id":0,"current_tick":31,"token":14274923382223712766},{"peer_id":2200039024721645,"clock_id":5,"current_tick":3,"token":16737324663161229622},{"peer_id":2200039024721645,"clock_id":2,"current_tick":13,"token":18171945371147883509},{"peer_id":2200039024721645,"clock_id":1,"current_tick":19,"token":13530503213804333634},{"peer_id":2200039024721645,"clock_id":3,"current_tick":5,"token":12159487072447257415},{"peer_id":2200039024721645,"clock_id":6,"current_tick":1,"token":9225203475475803001}]} {"clocks":[{"peer_id":2200039024721645,"clock_id":3,"current_tick":5,"token":12159487072447257415},{"peer_id":2200039024721645,"clock_id":4,"current_tick":3,"token":3225682797052271524},{"peer_id":2200039024721645,"clock_id":5,"current_tick":3,"token":16737324663161229622},{"peer_id":2200039024721645,"clock_id":6,"current_tick":1,"token":9225203475475803001},{"peer_id":2200039024721645,"clock_id":0,"current_tick":31,"token":14274923382223712766},{"peer_id":2200039024721645,"clock_id":1,"current_tick":19,"token":13530503213804333634},{"peer_id":2200039024721645,"clock_id":2,"current_tick":13,"token":18171945371147883509}]}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -1 +1 @@
{"clocks":[{"peer_id":2200039024721645,"clock_id":1,"current_tick":3,"token":1867745747127142053},{"peer_id":2200039024721645,"clock_id":2,"current_tick":1,"token":9487764786059616743},{"peer_id":2200039024721645,"clock_id":0,"current_tick":14,"token":3773126989639130100}]} {"clocks":[{"peer_id":2200039024721645,"clock_id":2,"current_tick":1,"token":9487764786059616743},{"peer_id":2200039024721645,"clock_id":1,"current_tick":3,"token":1867745747127142053},{"peer_id":2200039024721645,"clock_id":0,"current_tick":14,"token":3773126989639130100}]}

@ -2,91 +2,109 @@
{ {
"id":1, "id":1,
"title": "窮忙", "title": "窮忙",
"title_en": "Overworked",
"content": "你今天的行程裡,有多少比例是為了自己?" "content": "你今天的行程裡,有多少比例是為了自己?"
}, },
{ {
"id":2, "id":2,
"title": "內耗", "title": "內耗",
"title_en": "Internal Burnout",
"content": "你會花很多力氣處理自己的情緒嗎?" "content": "你會花很多力氣處理自己的情緒嗎?"
}, },
{ {
"id":3, "id":3,
"title": "學貸", "title": "學貸",
"title_en": "Student Loans",
"content": "一張畢業證書要花多少年來分期付款?" "content": "一張畢業證書要花多少年來分期付款?"
}, },
{ {
"id":4, "id":4,
"title": "租屋", "title": "租屋",
"title_en": "Renting",
"content": "這個月薪水的幾分之幾交給房東了?" "content": "這個月薪水的幾分之幾交給房東了?"
}, },
{ {
"id":5, "id":5,
"title": "成年", "title": "成年",
"title_en": "Adulthood",
"content": "法律定義的成年與你心理感受的成年,中間的距離有多少?" "content": "法律定義的成年與你心理感受的成年,中間的距離有多少?"
}, },
{ {
"id":6, "id":6,
"title": "規訓", "title": "規訓",
"title_en": "Discipline",
"content": "你所遵守的社交習慣,哪些是天生的、哪些是後來學會的?" "content": "你所遵守的社交習慣,哪些是天生的、哪些是後來學會的?"
}, },
{ {
"id":7, "id":7,
"title": "PUA", "title": "PUA",
"title_en": "PUA",
"content": "讓你自我懷疑的是事情本身,還是某人的評價?" "content": "讓你自我懷疑的是事情本身,還是某人的評價?"
}, },
{ {
"id":8, "id":8,
"title": "潛規則", "title": "潛規則",
"title_en": "Unwritten Rules",
"content": "有哪些規則是沒被寫出來,但你卻正在默默遵守的?" "content": "有哪些規則是沒被寫出來,但你卻正在默默遵守的?"
}, },
{ {
"id":9, "id":9,
"title": "社畜", "title": "社畜",
"title_en": "Corporate Slave",
"content": "你如何區分「工作時的你」與「下班後的你」?" "content": "你如何區分「工作時的你」與「下班後的你」?"
}, },
{ {
"id":10, "id":10,
"title": "邊界", "title": "邊界",
"title_en": "Boundaries",
"content": "你什麼時候會說不,來保護自己?" "content": "你什麼時候會說不,來保護自己?"
}, },
{ {
"id":11, "id":11,
"title": "監控", "title": "監控",
"title_en": "Surveillance",
"content": "如果沒人看見,你的行為表現會和現在有很大的差異嗎?" "content": "如果沒人看見,你的行為表現會和現在有很大的差異嗎?"
}, },
{ {
"id":12, "id":12,
"title": "自由", "title": "自由",
"title_en": "Freedom",
"content": "對你來說,什麼樣的狀態才叫「自由」?" "content": "對你來說,什麼樣的狀態才叫「自由」?"
}, },
{ {
"id":13, "id":13,
"title": "覺醒", "title": "覺醒",
"title_en": "Awakening",
"content": "你接受自己的出廠設定嗎?" "content": "你接受自己的出廠設定嗎?"
}, },
{ {
"id":14, "id":14,
"title": "躺平", "title": "躺平",
"title_en": "Lying Flat",
"content": "休息是因為想走更長的路,還是因為路已經走不下去了?" "content": "休息是因為想走更長的路,還是因為路已經走不下去了?"
}, },
{ {
"id":15, "id":15,
"title": "主體", "title": "主體",
"title_en": "Subjectivity",
"content": "在群體中,你通常是提出意見的人還是配合的人?" "content": "在群體中,你通常是提出意見的人還是配合的人?"
}, },
{ {
"id":16, "id":16,
"title": "做自己", "title": "做自己",
"title_en": "Being Oneself",
"content": "在公共場所,你覺得自己有多少程度能呈現真實的樣貌?" "content": "在公共場所,你覺得自己有多少程度能呈現真實的樣貌?"
}, },
{ {
"id":17, "id":17,
"title": "誰懂", "title": "誰懂",
"title_en": "Who Gets It",
"content": "你覺得目前身邊的人,誰真正理解你的處境?" "content": "你覺得目前身邊的人,誰真正理解你的處境?"
}, },
{ {
"id":18, "id":18,
"title": "焦慮", "title": "焦慮",
"title_en": "Anxiety",
"content": "你在擔心還沒發生的未來,還是後悔已經發生的過去?" "content": "你在擔心還沒發生的未來,還是後悔已經發生的過去?"
} }
] ]

@ -82,6 +82,7 @@ export default function Graph({results}){
let i=0; let i=0;
let average_distances={};
points.forEach((point, index)=>{ points.forEach((point, index)=>{
// if keyword, skip // if keyword, skip
if(results?.[index]?.type==='keyword') return; if(results?.[index]?.type==='keyword') return;
@ -104,6 +105,7 @@ export default function Graph({results}){
point point
); );
average_distances[group_index] = (average_distances[group_index] || 0) + revolution.radius;
sendOsc('/point',JSON.stringify({ sendOsc('/point',JSON.stringify({
index: i, index: i,
@ -114,7 +116,7 @@ export default function Graph({results}){
// dist: dist, // dist: dist,
// color: getColorByGroup(results?.[index]), // color: getColorByGroup(results?.[index]),
group: group_index, group: group_index,
radius: 2-revolution.radius*0.25, radius:revolution.radius,
axis_x: revolution.axis[0], axis_x: revolution.axis[0],
axis_y: revolution.axis[1], axis_y: revolution.axis[1],
axis_z: revolution.axis[2], axis_z: revolution.axis[2],
@ -125,12 +127,23 @@ export default function Graph({results}){
i++; i++;
}); });
keywords.forEach((point, index)=>{
const sorted_keywords = keywords.sort((a,b)=>{
const a_id=a.id;
const b_id=b.id;
return (a_id - b_id);
});
sorted_keywords.forEach((point, index)=>{
// console.log(`send osc Keyword Point ${index}: (${point[0].toFixed(2)}, ${point[1].toFixed(2)}, ${point[2].toFixed(2)})`); // console.log(`send osc Keyword Point ${index}: (${point[0].toFixed(2)}, ${point[1].toFixed(2)}, ${point[2].toFixed(2)})`);
const point_index=results?.indexOf(point); const point_index=results?.indexOf(point);
const keyword_point = point_index != -1 ? points[point_index] : [0,0,0]; const keyword_point = point_index != -1 ? points[point_index] : [0,0,0];
console.log("Keyword point:", keyword_point);
const content=JSON.parse(results?.[point_index]?.payload.text||'{}');
const group_index =index;
sendOsc('/keyword',JSON.stringify({ sendOsc('/keyword',JSON.stringify({
index: index, index: index,
@ -138,7 +151,9 @@ export default function Graph({results}){
x: keyword_point[0], x: keyword_point[0],
y: keyword_point[1], y: keyword_point[1],
z: keyword_point[2], z: keyword_point[2],
content: JSON.parse(results?.[index]?.payload.text||'{}').title || 'Keyword', content: `${content.title||''} ${content.title_en||''}` || 'Keyword',
average_distance: average_distances[group_index]/points.length,
color: getColorByGroup(results?.[index]), color: getColorByGroup(results?.[index]),
group: index, group: index,
})); }));

Loading…
Cancel
Save