Skip to content

Instantly share code, notes, and snippets.

View p3nGu1nZz's full-sized avatar
🌎
w o r k i n g • f r o m • s p a c e

p3ngu1nZz p3nGu1nZz

🌎
w o r k i n g • f r o m • s p a c e
  • N. America
View GitHub Profile
{"raw": "X-SPANFORMER\nSPAN-AwARE ENCODER\n5.4 Qualitative Span Interpretability\nTo assess the plausibility and semantic alignment of X-Spanformer's induced spans, we perform side-by-side comparisons against syntactic and semantic reference structures. Using single-sentence prompts drawn from the validation sets of WikiText and Stream-Mix, we visualize the top-K spans selected at various layers and entropy regimes. We benchmark span boundaries against:\nSyntactic parses: Constituents produced by Berkeley Neural Parser", "type": "mixed", "id": {"id": "a0409606-f532-4dd2-b02e-2a0bae5bfeee"}, "meta": {"status": "keep", "tags": [], "doc_language": "en", "extracted_by": "pdf2seg", "confidence": 0.78, "source_file": "XSpanformer_TokenizerFree_SpanAwareEncoder_RawsonChrzanowski_Preprint_v1.0_2025-06-26.pdf", "notes": "The segment contains a mix of technical terms and structured information that can be segmented into meaningful spans, such as \"X-SPANFORMER,\" \"SPAN-AwARE ENCODER,\" specific versions like \"5.4 Qua
@p3nGu1nZz
p3nGu1nZz / .py
Created December 2, 2024 14:14
EWC for fine-tuning models.
import torch
import torch.nn as nn
import torch.optim as optim
# Example model
class SimpleNN(nn.Module):
def __init__(self, input_size, hidden_size, output_size):
super(SimpleNN, self).__init__()
self.fc1 = nn.Linear(input_size, hidden_size)
self.fc2 = nn.Linear(hidden_size, output_size)
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Multiple Wobbly Plasma Bubbles</title>
</head>
<body>
## You
hi copilot, attached is our first conversation together in a series of conversations about our MarsGame made in unity 2023 HDRP with netcode for gameobjects. We just implement the basic game system state machine and everything seems to be working, i will attach part 2 of our last conversation in the next prompt
## Copilot
Hello, I'm glad to hear that you are making progress on your MarsGame project. It sounds like an exciting and challenging endeavor. 😊
I have read the file you uploaded, which contains the first part of our conversation about your game. Here are some of the main topics we discussed:
- The game concept and setting: You explained that your game is a multiplayer survival game set on Mars, where players have to explore, gather resources, build bases, and fight enemies.
- The game engine and graphics: You chose to use Unity 2023 HDRP, which is a high-end rendering pipeline that supports realistic lighting, shadows, reflections, and materials. You also mentioned some of the assets and tools
using System;
using System.Collections.Generic;
using UnityEngine;
namespace HFSM
{
public abstract class StateMachine<T>
{
T ctx;
using System;
public class Singleton<T> where T : class, new()
{
// The single instance of the type T
private static readonly Lazy<T> instance = new(() => new T());
// The private constructor to prevent outside instantiation
public Singleton() { }
using System;
using System.Collections.Generic;
using UnityEngine;
namespace HFSM
{
public class StateMachine<T> : Singleton<StateMachine<T>>
{
T context;
using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
namespace HFSM
{
/// <summary>
/// Our General Purspose Hieracrhial State Machine Engine. This class allows
/// sub states to bind addition nodes of states to create a tree structure. We also
~/code/as-boilerplater
➜ npm init
This utility will walk you through creating a package.json file.
It only covers the most common items, and tries to guess sensible defaults.
See `npm help json` for definitive documentation on these fields
and exactly what they do.
Use `npm install <pkg>` afterwards to install a package and
save it as a dependency in the package.json file.
#!/bin/bash
# IMPORTANT: Don't forget to logout from your Apple ID in the settings before running it!
# IMPORTANT: You will need to run this script from Recovery. In fact, macOS Catalina brings read-only filesystem which prevent this script from working from the main OS.
# This script needs to be run from the volume you wish to use.
# E.g. run it like this: cd /Volumes/Macintosh\ HD && sh /Volumes/Macintosh\ HD/Users/sabri/Desktop/disable.sh
# WARNING: It might disable things that you may not like. Please double check the services in the TODISABLE vars.
# Get active services: launchctl list | grep -v "\-\t0"
# Find a service: grep -lR [service] /System/Library/Launch* /Library/Launch* ~/Library/LaunchAgents