Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
|
@@ -545,7 +545,8 @@ hat_description = hat_block_data["description"]
|
|
| 545 |
#hat_description = hat_block_data.get("description", "No description available")
|
| 546 |
# hat_opcodes_functionalities = "\n".join([f" - Opcode: {block['op_code']}, functionality: {block['functionality']} example: standalone use: {block['example_standalone']}" for block in hat_block_data["blocks"]])
|
| 547 |
hat_opcodes_functionalities = "\n".join([
|
| 548 |
-
f" - Opcode: {block.get('op_code', 'N/A')}, functionality: {block.get('functionality', 'N/A')}, example: standalone use {block.get('example_standalone', 'N/A')}"
|
|
|
|
| 549 |
for block in hat_block_data.get("blocks", [])
|
| 550 |
]) if isinstance(hat_block_data.get("blocks"), list) else " No blocks information available."
|
| 551 |
#hat_opcodes_functionalities = os.path.join(BLOCKS_DIR, "hat_blocks.txt")
|
|
@@ -555,7 +556,8 @@ boolean_block_data = _load_block_catalog(BOOLEAN_BLOCKS_PATH)
|
|
| 555 |
boolean_description = boolean_block_data["description"]
|
| 556 |
# boolean_opcodes_functionalities = "\n".join([f" - Opcode: {block['op_code']}, functionality: {block['functionality']} example: standalone use: {block['example_standalone']}" for block in boolean_block_data["blocks"]])
|
| 557 |
boolean_opcodes_functionalities = "\n".join([
|
| 558 |
-
f" - Opcode: {block.get('op_code', 'N/A')}, functionality: {block.get('functionality', 'N/A')}, example: standalone use {block.get('example_standalone', 'N/A')}"
|
|
|
|
| 559 |
for block in boolean_block_data.get("blocks", [])
|
| 560 |
]) if isinstance(boolean_block_data.get("blocks"), list) else " No blocks information available."
|
| 561 |
#boolean_opcodes_functionalities = os.path.join(BLOCKS_DIR, "boolean_blocks.txt")
|
|
@@ -564,7 +566,8 @@ c_block_data = _load_block_catalog(C_BLOCKS_PATH)
|
|
| 564 |
c_description = c_block_data["description"]
|
| 565 |
# c_opcodes_functionalities = "\n".join([f" - Opcode: {block['op_code']}, functionality: {block['functionality']} example: standalone use: {block['example_standalone']}" for block in c_block_data["blocks"]])
|
| 566 |
c_opcodes_functionalities = "\n".join([
|
| 567 |
-
f" - Opcode: {block.get('op_code', 'N/A')}, functionality: {block.get('functionality', 'N/A')}, example: standalone use {block.get('example_standalone', 'N/A')}"
|
|
|
|
| 568 |
for block in c_block_data.get("blocks", [])
|
| 569 |
]) if isinstance(c_block_data.get("blocks"), list) else " No blocks information available."
|
| 570 |
#c_opcodes_functionalities = os.path.join(BLOCKS_DIR, "c_blocks.txt")
|
|
@@ -573,7 +576,8 @@ cap_block_data = _load_block_catalog(CAP_BLOCKS_PATH)
|
|
| 573 |
cap_description = cap_block_data["description"]
|
| 574 |
# cap_opcodes_functionalities = "\n".join([f" - Opcode: {block['op_code']}, functionality: {block['functionality']} example: standalone use: {block['example_standalone']}" for block in cap_block_data["blocks"]])
|
| 575 |
cap_opcodes_functionalities = "\n".join([
|
| 576 |
-
f" - Opcode: {block.get('op_code', 'N/A')}, functionality: {block.get('functionality', 'N/A')}, example: standalone use {block.get('example_standalone', 'N/A')}"
|
|
|
|
| 577 |
for block in cap_block_data.get("blocks", [])
|
| 578 |
]) if isinstance(cap_block_data.get("blocks"), list) else " No blocks information available."
|
| 579 |
#cap_opcodes_functionalities = os.path.join(BLOCKS_DIR, "cap_blocks.txt")
|
|
@@ -582,7 +586,8 @@ reporter_block_data = _load_block_catalog(REPORTER_BLOCKS_PATH)
|
|
| 582 |
reporter_description = reporter_block_data["description"]
|
| 583 |
# reporter_opcodes_functionalities = "\n".join([f" - Opcode: {block['op_code']}, functionality: {block['functionality']} example: standalone use: {block['example_standalone']}" for block in reporter_block_data["blocks"]])
|
| 584 |
reporter_opcodes_functionalities = "\n".join([
|
| 585 |
-
f" - Opcode: {block.get('op_code', 'N/A')}, functionality: {block.get('functionality', 'N/A')}, example: standalone use {block.get('example_standalone', 'N/A')}"
|
|
|
|
| 586 |
for block in reporter_block_data.get("blocks", [])
|
| 587 |
]) if isinstance(reporter_block_data.get("blocks"), list) else " No blocks information available."
|
| 588 |
#reporter_opcodes_functionalities = os.path.join(BLOCKS_DIR, "reporter_blocks.txt")
|
|
@@ -591,7 +596,8 @@ stack_block_data = _load_block_catalog(STACK_BLOCKS_PATH)
|
|
| 591 |
stack_description = stack_block_data["description"]
|
| 592 |
# stack_opcodes_functionalities = "\n".join([f" - Opcode: {block['op_code']}, functionality: {block['functionality']} example: standalone use: {block['example_standalone']}" for block in stack_block_data["blocks"]])
|
| 593 |
stack_opcodes_functionalities = "\n".join([
|
| 594 |
-
f" - Opcode: {block.get('op_code', 'N/A')}, functionality: {block.get('functionality', 'N/A')}, example: standalone use {block.get('example_standalone', 'N/A')}"
|
|
|
|
| 595 |
for block in stack_block_data.get("blocks", [])
|
| 596 |
]) if isinstance(stack_block_data.get("blocks"), list) else " No blocks information available."
|
| 597 |
#stack_opcodes_functionalities = os.path.join(BLOCKS_DIR, "stack_blocks.txt")
|
|
|
|
| 545 |
#hat_description = hat_block_data.get("description", "No description available")
|
| 546 |
# hat_opcodes_functionalities = "\n".join([f" - Opcode: {block['op_code']}, functionality: {block['functionality']} example: standalone use: {block['example_standalone']}" for block in hat_block_data["blocks"]])
|
| 547 |
hat_opcodes_functionalities = "\n".join([
|
| 548 |
+
# f" - Opcode: {block.get('op_code', 'N/A')}, functionality: {block.get('functionality', 'N/A')}, example: standalone use {block.get('example_standalone', 'N/A')}"
|
| 549 |
+
f" - Opcode: {block.get('op_code', 'N/A')}, example: standalone use {block.get('example_standalone', 'N/A')}"
|
| 550 |
for block in hat_block_data.get("blocks", [])
|
| 551 |
]) if isinstance(hat_block_data.get("blocks"), list) else " No blocks information available."
|
| 552 |
#hat_opcodes_functionalities = os.path.join(BLOCKS_DIR, "hat_blocks.txt")
|
|
|
|
| 556 |
boolean_description = boolean_block_data["description"]
|
| 557 |
# boolean_opcodes_functionalities = "\n".join([f" - Opcode: {block['op_code']}, functionality: {block['functionality']} example: standalone use: {block['example_standalone']}" for block in boolean_block_data["blocks"]])
|
| 558 |
boolean_opcodes_functionalities = "\n".join([
|
| 559 |
+
# f" - Opcode: {block.get('op_code', 'N/A')}, functionality: {block.get('functionality', 'N/A')}, example: standalone use {block.get('example_standalone', 'N/A')}"
|
| 560 |
+
f" - Opcode: {block.get('op_code', 'N/A')}, example: standalone use {block.get('example_standalone', 'N/A')}"
|
| 561 |
for block in boolean_block_data.get("blocks", [])
|
| 562 |
]) if isinstance(boolean_block_data.get("blocks"), list) else " No blocks information available."
|
| 563 |
#boolean_opcodes_functionalities = os.path.join(BLOCKS_DIR, "boolean_blocks.txt")
|
|
|
|
| 566 |
c_description = c_block_data["description"]
|
| 567 |
# c_opcodes_functionalities = "\n".join([f" - Opcode: {block['op_code']}, functionality: {block['functionality']} example: standalone use: {block['example_standalone']}" for block in c_block_data["blocks"]])
|
| 568 |
c_opcodes_functionalities = "\n".join([
|
| 569 |
+
# f" - Opcode: {block.get('op_code', 'N/A')}, functionality: {block.get('functionality', 'N/A')}, example: standalone use {block.get('example_standalone', 'N/A')}"
|
| 570 |
+
f" - Opcode: {block.get('op_code', 'N/A')}, example: standalone use {block.get('example_standalone', 'N/A')}"
|
| 571 |
for block in c_block_data.get("blocks", [])
|
| 572 |
]) if isinstance(c_block_data.get("blocks"), list) else " No blocks information available."
|
| 573 |
#c_opcodes_functionalities = os.path.join(BLOCKS_DIR, "c_blocks.txt")
|
|
|
|
| 576 |
cap_description = cap_block_data["description"]
|
| 577 |
# cap_opcodes_functionalities = "\n".join([f" - Opcode: {block['op_code']}, functionality: {block['functionality']} example: standalone use: {block['example_standalone']}" for block in cap_block_data["blocks"]])
|
| 578 |
cap_opcodes_functionalities = "\n".join([
|
| 579 |
+
# f" - Opcode: {block.get('op_code', 'N/A')}, functionality: {block.get('functionality', 'N/A')}, example: standalone use {block.get('example_standalone', 'N/A')}"
|
| 580 |
+
f" - Opcode: {block.get('op_code', 'N/A')}, example: standalone use {block.get('example_standalone', 'N/A')}"
|
| 581 |
for block in cap_block_data.get("blocks", [])
|
| 582 |
]) if isinstance(cap_block_data.get("blocks"), list) else " No blocks information available."
|
| 583 |
#cap_opcodes_functionalities = os.path.join(BLOCKS_DIR, "cap_blocks.txt")
|
|
|
|
| 586 |
reporter_description = reporter_block_data["description"]
|
| 587 |
# reporter_opcodes_functionalities = "\n".join([f" - Opcode: {block['op_code']}, functionality: {block['functionality']} example: standalone use: {block['example_standalone']}" for block in reporter_block_data["blocks"]])
|
| 588 |
reporter_opcodes_functionalities = "\n".join([
|
| 589 |
+
# f" - Opcode: {block.get('op_code', 'N/A')}, functionality: {block.get('functionality', 'N/A')}, example: standalone use {block.get('example_standalone', 'N/A')}"
|
| 590 |
+
f" - Opcode: {block.get('op_code', 'N/A')}, example: standalone use {block.get('example_standalone', 'N/A')}"
|
| 591 |
for block in reporter_block_data.get("blocks", [])
|
| 592 |
]) if isinstance(reporter_block_data.get("blocks"), list) else " No blocks information available."
|
| 593 |
#reporter_opcodes_functionalities = os.path.join(BLOCKS_DIR, "reporter_blocks.txt")
|
|
|
|
| 596 |
stack_description = stack_block_data["description"]
|
| 597 |
# stack_opcodes_functionalities = "\n".join([f" - Opcode: {block['op_code']}, functionality: {block['functionality']} example: standalone use: {block['example_standalone']}" for block in stack_block_data["blocks"]])
|
| 598 |
stack_opcodes_functionalities = "\n".join([
|
| 599 |
+
# f" - Opcode: {block.get('op_code', 'N/A')}, functionality: {block.get('functionality', 'N/A')}, example: standalone use {block.get('example_standalone', 'N/A')}"
|
| 600 |
+
f" - Opcode: {block.get('op_code', 'N/A')}, example: standalone use {block.get('example_standalone', 'N/A')}"
|
| 601 |
for block in stack_block_data.get("blocks", [])
|
| 602 |
]) if isinstance(stack_block_data.get("blocks"), list) else " No blocks information available."
|
| 603 |
#stack_opcodes_functionalities = os.path.join(BLOCKS_DIR, "stack_blocks.txt")
|