Qwen/Qwen2.5-0.5B · L12/N4099 · 20261031T000400Z
Experiment 4 of 4 on this neuron, most conclusive first · record
The positive side of this neuron is the counterpart of its verified negative pole: it fires on a token that is a later/internal piece of a machine-formatted string - a snake_case/camelCase identifier or argument, a dotted qualified import name, a number such as a year or version, or a repeated format element - when that string sits inside a code, markup, comment or template construct with a fixed, rehearsed form (e.g. `_length` in `CharField(max_length = 255)`, `files` in `{% load staticfiles %}`, `.slf` in `import org.slf4j.LoggerFactory;`, the interior digits of `2016` in a `// Copyright` header, the third `M` of `"EEEE d MMMM y"`, `-` in `encoding="utf-8"`). It stays near zero when the same words occur in prose, on whole-word tokens, on pieces of ordinary alphabetic words, and on the rare names that drive the negative pole (Coldwell Banker, Daler-Rowney, HMC5883L), which is the distinction the two poles draw: rare name whose completion must be retrieved (negative) versus familiar machine-formatted string whose continuation is set by the format (positive).
The whole hypothesis
The positive side of this neuron is the counterpart of its verified negative pole: it fires on a token that is a later/internal piece of a machine-formatted string - a snake_case/camelCase identifier or argument, a dotted qualified import name, a number such as a year or version, or a repeated format element - when that string sits inside a code, markup, comment or template construct with a fixed, rehearsed form (e.g. `_length` in `CharField(max_length = 255)`, `files` in `{% load staticfiles %}`, `.slf` in `import org.slf4j.LoggerFactory;`, the interior digits of `2016` in a `// Copyright` header, the third `M` of `"EEEE d MMMM y"`, `-` in `encoding="utf-8"`). It stays near zero when the same words occur in prose, on whole-word tokens, on pieces of ordinary alphabetic words, and on the rare names that drive the negative pole (Coldwell Banker, Daler-Rowney, HMC5883L), which is the distinction the two poles draw: rare name whose completion must be retrieved (negative) versus familiar machine-formatted string whose continuation is set by the format (positive).
Hard negatives 10/10 rejected · holdouts 4/6 fired (independent observations; 16 probes) · P(useful) 0.96 · re-measures the probes of 20261024T060914Z; not independent evidence
specificity 1.00 · sensitivity 0.67 · counterfactual reproduction 1.00 · protocol v0.8
_lengthfiles.slf.LoggerFactory = ==-smM.File21 encoding staticize.cssforegroundframeborder
Adversarial review
positive_holdout: 4/6 passed; hard_negative: 10/10 passed; counterfactual: 9/9 passed; lookahead_consistency: 1/1 passed. All gates passed.
All 26 probes
| Test | Input | Expected | Observed | |
|---|---|---|---|---|
| ✗ | positive holdout | import { createSlice } from '@reduxjs/toolkit';
import type { PayloadAction } from '@reduxjs/toolkit';
const userSlice = createSlice({
name: 'userProfile',
initialState: { userId: null, isLoading: false },
reducers: {
setUserId(state, action: PayloadAction<string>) {
state.userId = action.payload;
},
},
});
export default userSlice.reducer; Novel TypeScript code with camelCase identifiers (userSlice, userProfile, userId, isLoading, PayloadAction) inside a fixed import/slice construct, so the hypothesis predicts the internal camelCase pieces fire. |
active | 0.236 |
| ✓ | positive holdout | // Copyright 2019 The Netty Project. Licensed under the Apache License, Version 2.0.
package io.netty.channel.nio;
import io.netty.util.concurrent.EventExecutorGroup;
import org.apache.logging.log4j.Logger;
public final class NioEventLoopGroup extends MultithreadEventLoopGroup {
} A different copyright header and dotted package imports than the examples, so the hypothesis predicts the interior year digits in the comment and later dotted-import pieces fire. |
active | 0.494 |
| ✓ | positive holdout | internal static class DateFormats
{
public const string LongDate = "dddd, MMMM d, yyyy";
public const string Timestamp = "yyyy-MM-dd'T'HH:mm:ss.fff";
public const string ShortTime = "h:mm tt";
} C# date-format constants with repeated M/y elements and hyphen/colon pieces are a paraphrase of the "EEEE d MMMM y" example in a new language, so the hypothesis predicts the repeated format elements fire. |
active | 0.534 |
| ✗ | positive holdout | version: "3.9"
services:
web:
image: python:3.11-slim
environment:
DJANGO_SETTINGS_MODULE: config.settings.production
DATABASE_URL: postgresql://app:[email protected]:5432/orders
command: gunicorn config.wsgi:application --bind 0.0.0.0:8000 --workers 3
depends_on:
- db
db:
image: postgres:15.4-alpine
volumes:
- pgdata:/var/lib/postgresql/data
volumes:
pgdata: A docker-compose file with version tags, dotted module paths and hyphenated flags in a fixed config schema, so the hypothesis predicts the internal pieces of those machine-formatted strings fire. |
active | 0.205 |
| ✓ | positive holdout | Deploying a small Django application behind nginx surprises most people the first time they try it, because three separate moving parts fail in ways that look like the fault of the other two. The application server has to be running and reachable on a local port. The web server has to know that this port exists and has to forward the right headers so that the application can build correct absolute links. And the static assets have to be served by something fast, because asking Python to return a stylesheet is a waste of a worker.
A useful habit is to start from the smallest setup that can possibly work, confirm that a plain page loads, and only then add TLS, caching and compression. People who begin with a fully copied configuration from a blog post usually end up with three unrelated problems at once: a misspelled socket path, a missing trailing slash on a location, and a certificate chain that the browser quietly refuses. Each of these produces a different error page, and none of them mentions the real cause.
The next step is to put the configuration under version control and to keep a comment above every block explaining why the block exists. Six months later nobody remembers which rewrite rule is load-bearing. A short note such as "forward the original scheme so that Django does not downgrade redirects" saves an afternoon. It also makes reviews easier, because a reviewer can see immediately whether a change is meant to alter behaviour or merely to reorganise the file.
Rollbacks deserve the same care. Before changing anything in production, write down the exact command that restores the previous release, and check that the previous release is still available on disk. A rollback that depends on a package registry staying online is not a rollback. Keep the old virtual environment, the old assets and the old configuration file side by side with the new ones, and remove them only after a quiet week.
Finally, test the deployment from outside the machine. Curl from localhost hides proxy problems, and a browser with a warm cache hides header problems. After the site is live, watch the access log for the first hour and confirm that assets are being served by the web server rather than by the application.
The server block that all of this refers to looks like this:
server {
listen 443 ssl http2;
server_name shop.example.com;
ssl_certificate /etc/letsencrypt/live/shop.example.com/fullchain.pem;
ssl_protocols TLSv1.2 TLSv1.3;
location /static/ {
alias /srv/app/staticfiles/;
expires 30d;
}
location / {
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_pass http://unix:/run/gunicorn.sock;
}
} The feature sits at the end of a long deployment guide inside an nginx block with snake_case directives, hyphenated header names and version strings, so the hypothesis predicts activation and this tests long context and end-of-document position. |
active | 0.289 |
| ✓ | positive holdout | CREATE TABLE user_accounts (
account_id BIGINT PRIMARY KEY,
display_name VARCHAR(255) NOT NULL,
email_address VARCHAR(320) UNIQUE,
created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP
);
CREATE INDEX idx_user_accounts_email ON user_accounts (email_address); SQL DDL with snake_case column names and numeric type widths in a fixed CREATE TABLE form, so the hypothesis predicts the internal pieces of those identifiers fire. |
active | 0.353 |
| ✓ | hard negative | We copied the static files to the staging server and checked the encoding of each metadata field before the release. The trigger words 'static files' and 'encoding' appear only in ordinary prose with no code, markup or template construct, which the hypothesis says stays near zero. |
inactive | 0.065 |
| ✓ | hard negative | In the review, someone asked why max_length was never set on the name field, so I added it to the form. The peak token max_length of example 1 appears as a bare mention in prose rather than inside a CharField argument list, and the hypothesis predicts prose suppresses it. |
inactive | 0.216 |
| ✓ | hard negative | She did not recognize the organizer of the socialization workshop, despite the personalized invitation. Only pieces of ordinary alphabetic words (recognize, organizer, socialization, personalized) occur, which the hypothesis says do not fire. |
inactive | 0.096 |
| ✓ | hard negative | Coldwell Banker and Daler-Rowney shared a booth at the fair, and an HMC5883L compass module sat on the table next to it. The rare names that drive the negative pole (Coldwell Banker, Daler-Rowney, HMC5883L) appear without any fixed-form construct, and the hypothesis predicts the positive side stays near zero on them. |
inactive | 0.057 |
| ✓ | hard negative | {% block content %}Thanks for visiting our site{% endblock %} Same template delimiters and template keywords as the activating examples but only plain words inside, and the hypothesis predicts no machine-formatted string means no activation. |
inactive | 0.035 |
| ✓ | hard negative | logged_in is the flag you need; it tells the view whether the session exists. A snake_case identifier at the very start of a prose sentence tests whether position alone can rescue a formatted string that lacks a code construct, and the hypothesis predicts inactive. |
inactive | 0.098 |
| ✓ | hard negative | My Django form never appears on the page. I followed a tutorial, the view returns a response, but the template stays empty. Which part should I check first? Same Django troubleshooting topic as the examples but with no identifiers, numbers or dotted names, testing that the topic alone does not fire the pole. |
inactive | 0.100 |
| ✓ | hard negative | The library was founded in 2016, and version 2.4.1 shipped three years later. A year and a version number appear in ordinary prose rather than in a copyright header or code construct, and the hypothesis predicts numbers outside fixed forms stay near zero. |
inactive | 0.069 |
| ✓ | hard negative | Full details are at https://example.com/2016/06/django-forms if you want to read more. A bare URL in prose containing dotted segments, slashes and year-like digits is a near-miss for a dotted qualified name outside any code construct, which the hypothesis predicts is inactive. |
inactive | 0.056 |
| ✓ | hard negative | The team renamed the widget to ListView and everyone agreed the new name was clearer. A camelCase class name (ListView) used as a whole word in prose tests the hypothesis's claim that whole-word tokens outside code stay near zero. |
inactive | 0.152 |
| ✓ | counterfactual | person1 = models.CharField(max_length = 255) -> The field setting named max_length controls the maximum size | Δ 0.47 | Δ 0.47 |
| ✓ | counterfactual | import org.slf4j.LoggerFactory; -> import java.util.HashMap; | Δ 0.75 | Δ 0.75 |
| ✓ | counterfactual | if __name__ == '__main__': -> if the name equals main: | Δ 0.81 | Δ 0.81 |
| ✓ | counterfactual | // Copyright 2016 The Chromium Authors -> Copyright 2016 The Chromium Authors | Δ 0.25 | Δ 0.25 |
| ✓ | counterfactual | <?xml version="1.0" encoding="utf-8"?> -> <?xml version="1.0" charset="utf-8"?> | Δ 0.26 | Δ 0.26 |
| ✓ | counterfactual | "fullDate": "EEEE d MMMM y", -> "fullDate": "EEEE d MMM y", | Δ 0.37 | Δ 0.37 |
| ✓ | counterfactual | Contact a Coldwell Banker agent to request more information. -> Contact a Coldwell Banker broker to request more information. | Δ 0.00 | Δ 0.00 |
| ✓ | counterfactual | ## Copyright 2016 The Chromium Authors -> // Copyright 2016 The Chromium Authors | Δ 0.04 | Δ 0.04 |
| ✓ | counterfactual | person1 = models.CharField(max_length = 255) -> person1 = models.CharField(max length = 255) | Δ 0.08 | Δ 0.08 |
| ✓ | lookahead consistency | person1 = models.CharField(max_length = 255); import org.slf4j.LoggerFactory;; if __name__ == '__main__':; // Copyright 2016 The Chromium Authors; <?xml version="1.0" encoding="utf-8"?>; "fullDate": "EEEE d MMMM y",; Contact a Coldwell Banker agent to request more information.; ## Copyright 2016 The Chromium Authors; person1 = models.CharField(max_length = 255) claimed retrospective; measured retrospective (KL=3.052e-05, tokens=[',', '3', ' yyyy', " '__", '\n\n']) |
Minimal pairs
| # | Base → counterfactual | Expected Δ | Observed Δ | Sufficiency | Necessity |
|---|---|---|---|---|---|
| 1 | person1 = models.CharField(max_length = 255) → The field setting named max_length controls the maximum size |
0.47 | 0.47 | — | — |
| 2 | import org.slf4j.LoggerFactory; → import java.util.HashMap; |
0.75 | 0.75 | — | — |
| 3 | if __name__ == '__main__': → if the name equals main: |
0.81 | 0.81 | — | — |
| 4 | // Copyright 2016 The Chromium Authors → Copyright 2016 The Chromium Authors |
0.25 | 0.25 | — | — |
| 5 | <?xml version="1.0" encoding="utf-8"?> → <?xml version="1.0" charset="utf-8"?> |
0.26 | 0.26 | 0.62 effect 9.74e-07 matched 6.07e-07 / 9.34e-06 |
0.25 effect 0 matched 8e-09 / 1.77e-07 |
| 6 | "fullDate": "EEEE d MMMM y", → "fullDate": "EEEE d MMM y", |
0.37 | 0.37 | — | — |
| 7 | Contact a Coldwell Banker agent to request more information. → Contact a Coldwell Banker broker to request more information. |
0.00 | 0.00 | — | — |
| 8 | ## Copyright 2016 The Chromium Authors → // Copyright 2016 The Chromium Authors |
0.04 | 0.04 | — | — |
| 9 | person1 = models.CharField(max_length = 255) → person1 = models.CharField(max length = 255) |
0.08 | 0.08 | 0.84 effect 3.79e-06 matched 5.5e-07 / 1.36e-05 |
0.06 effect 0 matched 2.41e-07 / 3.22e-06 |
Read more
Δ is the base prompt's peak positive-pole strength minus the counterfactual's, as a fraction of the max activation.
Each causal score ranks the pole's patch effect among the 32 same-layer neurons that change as much between each pair, so 0.5 is typical. Sufficiency patches clean into corrupted, and necessity corrupted into clean. The score is the median over 2 non-control pairs, on next-token KL. Median effect 2.38e-06 (sufficiency) and 0 (necessity). In the table, each cell gives the percentile, the pole's signed effect, and the matched neurons' median and largest |effect|, in nats of KL. Self-repair (the hydra effect) was mitigated by freezing downstream MLP outputs.
Top-activating examples
Hover a token for its value.
-
1.08
… import models↵↵class Kiss(models.Model):↵ latitude = models.FloatField()↵ longitude = models.FloatField()↵ person1 = models.CharField(max_length = 255)↵ person2 …
All 367 tokens
Q:↵↵Django ModelForm not showing up in template↵↵I've been using django for a couple of days now and I'm trying to create a small app to learn the whole stuff.↵I've read about the ModelForms and I wanted to use it in my app, but I can't get it to render in my template and I can't find the problem, so I was hoping you guys could help me out.↵Here's my code:↵models.py↵from django.db import models↵↵class Kiss(models.Model):↵ latitude = models.FloatField()↵ longitude = models.FloatField()↵ person1 = models.CharField(max_length = 255)↵ person2 = models.CharField(max_length = 255)↵ cdate = models.DateTimeField(auto_now_add=True)↵↵ def __unicode__(self):↵ return self.person1↵↵views.py↵from django.views.generic.list import ListView↵from project.models import Kiss↵from project.forms import KissForm↵from django.http import HttpResponseRedirect↵↵class KissListView(ListView):↵ template_name = 'project/home.html'↵ model = Kiss↵ form = KissForm↵↵urls.py (only the relevant part)↵urlpatterns += patterns('',↵ url(r'^$', KissListView.as_view(), name='home'),↵ )↵↵forms.py↵from django import forms↵from project.models import Kiss↵↵class KissForm(forms.ModelForm):↵ class Meta:↵ model = Kiss↵↵and the template↵<form action="" method="POST">↵ {% csrf_token %}↵ {{form.as_p}}↵ <button>Send</button>↵ </form>↵↵Thanks in advance for your help.↵J↵↵A:↵↵class KissListView(ListView):↵...↵↵You are using ListView which does not require form and will not give you form in the template context.↵You may want to use CreateView instead.↵↵
Values
Token Positive-pole strength import0.086 models0.101 ↵↵0.000 class0.000 Kiss0.040 (models0.000 .Model0.000 ):↵0.073 0.000 latitude0.000 0.000 =0.011 models0.064 .FloatField0.114 ()↵0.000 0.000 longitude0.035 0.000 =0.000 models0.057 .FloatField0.009 ()↵0.000 0.000 person0.000 10.031 0.000 =0.000 models0.027 .CharField0.000 (max0.620 _length1.076 =0.220 0.000 20.000 50.234 50.101 )↵0.000 0.000 person0.000 20.120 0.000 -
1.00
… etc). I have other js functions in functions.js that work fine. ↵test.html:↵{% csrf_token %}↵{% load groupfilter %}↵{% load staticfiles %}↵<!DOCTYPE html>↵<html lang="en">↵ …
All 741 tokens
Q:↵↵Bootstrap tree-view: Tree doesn't show up↵↵I'm new to tree-view, I'm trying to show a basic tree but it doesn't work and I don't know where I made the mistake.↵I made test.html that follow the same structure of my basic.html (I'm sparing you code of the navbar, alerts, etc). I have other js functions in functions.js that work fine. ↵test.html:↵{% csrf_token %}↵{% load groupfilter %}↵{% load staticfiles %}↵<!DOCTYPE html>↵<html lang="en">↵ <head>↵ <meta name="viewport" content="width=device-width, initial-scale=1" charset="utf-8">↵ <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css" integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T" crossorigin="anonymous">↵ <link rel="stylesheet" href="{% static 'bootstrap-treeview.min.css' %}">↵ <script src="{% static 'bootstrap-treeview.min.js' %}"></script>↵ <script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script>↵ <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.7/umd/popper.min.js" integrity="sha384-UO2eT0CpHqdSJQ6hJty5KVphtPhzWj9WO1clHTMGa3JDZwrnQq4sF86dIHNDz0W1" crossorigin="anonymous"></script>↵ <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js" integrity="sha384-JjSmVgyd0p3pXB1rRibZUAYoIIy6OrQ6VrjIEaFf/nJGzIxFDsf4x0xIM+B07jRM" crossorigin="anonymous"></script>↵↵ <title>Test</title>↵ </head>↵ <body>↵ <div class="container">↵ <div id="tree"></div>↵ </div>↵ <!-- JavaScript functions -->↵ <script src="{% static 'functions.js' %}"></script>↵ </body>↵</html>↵↵extract of functions.js:↵$(function(){↵ var mytree = [↵ {↵ text: "Parent 1",↵ nodes: [↵ {↵ text: "Child 1",↵ nodes: [↵ {↵ text: "Grandchild 1"↵ },↵ {↵ text: "Grandchild 2"↵ }↵ ]↵ },↵ {↵ text: "Child 2"↵ }↵ ]↵ },↵ {↵ text: "Parent 2"↵ }↵ ];↵↵ $('#tree').treeview({data: mytree});↵});↵↵A:↵↵Can you share sample link that you are following?↵It seems like you are importing Twitter Bootstrap 4.3.1↵↵But as I know, Offical Bootstrap still not provide TreeView on their document.↵↵
Values
Token Positive-pole strength etc0.073 ).0.000 I0.000 have0.000 other0.000 js0.000 functions0.000 in0.000 functions0.010 .js0.000 that0.000 work0.002 fine0.045 .0.000 ↵0.000 test0.078 .html0.000 :↵0.081 {%0.000 csrf0.000 _token0.005 %}↵0.000 {%0.000 load0.101 group0.105 filter0.209 %}↵0.000 {%0.005 load0.062 static0.642 files0.996 %}↵0.000 <!0.000 DOCTYPE0.000 html0.004 >↵0.015 <html0.000 lang0.000 ="0.051 en0.215 ">↵0.000 -
0.87
// Copyright 2000-2020 JetBrains s.r.o. Use of this source …
All 627 tokens
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.↵package com.intellij.openapi.vcs.impl↵↵import com.intellij.ProjectTopics↵import com.intellij.openapi.application.ApplicationManager↵import com.intellij.openapi.components.service↵import com.intellij.openapi.extensions.ExtensionNotApplicableException↵import com.intellij.openapi.module.Module↵import com.intellij.openapi.module.ModuleManager↵import com.intellij.openapi.project.ModuleListener↵import com.intellij.openapi.project.Project↵import com.intellij.openapi.project.rootManager↵import com.intellij.openapi.roots.ModuleRootEvent↵import com.intellij.openapi.roots.ModuleRootListener↵import com.intellij.openapi.startup.StartupActivity↵import com.intellij.openapi.vcs.AbstractVcs↵import com.intellij.openapi.vcs.ProjectLevelVcsManager↵import com.intellij.openapi.vcs.VcsDirectoryMapping↵import com.intellij.openapi.vfs.VirtualFile↵↵internal class ModuleVcsDetector(private val project: Project) {↵ private val vcsManager by lazy(LazyThreadSafetyMode.NONE) {↵ (ProjectLevelVcsManager.getInstance(project) as ProjectLevelVcsManagerImpl)↵ }↵↵ internal class MyPostStartUpActivity : StartupActivity.DumbAware {↵ init {↵ if (ApplicationManager.getApplication().isUnitTestMode) {↵ throw ExtensionNotApplicableException.INSTANCE↵ }↵ }↵↵ override fun runActivity(project: Project) {↵ val vcsDetector = project.service<ModuleVcsDetector>()↵↵ val listener = vcsDetector.MyModulesListener()↵ val busConnection = project.messageBus.connect()↵ busConnection.subscribe(ProjectTopics.MODULES, listener)↵ busConnection.subscribe(ProjectTopics.PROJECT_ROOTS, listener)↵↵ if (vcsDetector.vcsManager.needAutodetectMappings()) {↵ vcsDetector.autoDetectVcsMappings(true)↵ }↵ }↵ }↵↵ private inner class MyModulesListener : ModuleRootListener, ModuleListener {↵ private val myMappingsForRemovedModules: MutableList<VcsDirectoryMapping> = mutableListOf()↵↵ override fun beforeRootsChange(event: ModuleRootEvent) {↵ myMappingsForRemovedModules.clear()↵ }↵↵ override fun rootsChanged(event: ModuleRootEvent) {↵ myMappingsForRemovedModules.forEach { mapping -> vcsManager.removeDirectoryMapping(mapping) }↵ // the check calculates to true only before user has done any change to mappings, i.e. in case modules are detected/added automatically↵ // on start etc (look inside)↵ if (vcsManager.needAutodetectMappings()) {↵ autoDetectVcsMappings(false)↵ }↵ }↵↵ override fun moduleAdded(project: Project, module: Module) {↵ myMappingsForRemovedModules.removeAll(getMappings(module))↵ autoDetectModuleVcsMapping(module)↵ }↵↵ override fun beforeModuleRemoved(project: Project, module: Module) {↵ myMappingsForRemovedModules.addAll(getMappings(module))↵ }↵ }↵↵ private fun autoDetectVcsMappings(tryMapPieces: Boolean) {↵ if (vcsM
Values
Token Positive-pole strength //0.035 Copyright0.117 0.000 20.000 00.494 00.442 00.000 -0.153 20.000 00.393 20.869 00.000 JetBrains0.000 s0.000 .r0.000 .o0.000 .0.000 Use0.000 of0.000 this0.000 source0.000 -
0.82
… wrong or I'm losing my mind.↵Here is the image↵Here is the XML code↵<?xml version="1.0" encoding="utf-8"?>↵<android.support.constraint.ConstraintLayout ↵xmlns …
All 653 tokens
Q:↵↵TextView Not centered in app but centered in match_constraint↵↵I've created a simple activity design using ConstraintLayout.↵Whenever I try to center a textView, it does it correctly in the blueprints but never does it in the actual app. Not sure if i am doing something wrong or I'm losing my mind.↵Here is the image↵Here is the XML code↵<?xml version="1.0" encoding="utf-8"?>↵<android.support.constraint.ConstraintLayout ↵xmlns:android="http://schemas.android.com/apk/res/android"↵xmlns:app="http://schemas.android.com/apk/res-auto"↵xmlns:tools="http://schemas.android.com/tools"↵android:layout_width="match_parent"↵android:layout_height="match_parent"↵android:background="@color/background_green"↵tools:context="nz.co.listcosolutions.StartActivity">↵↵<ImageView↵ android:id="@+id/imageView4"↵ android:layout_width="160dp"↵ android:layout_height="163dp"↵ android:layout_marginEnd="95dp"↵ android:layout_marginStart="95dp"↵ android:layout_marginTop="32dp"↵ app:layout_constraintEnd_toEndOf="parent"↵ app:layout_constraintStart_toStartOf="parent"↵ app:layout_constraintTop_toTopOf="parent"↵ app:srcCompat="@drawable/baby_plant" />↵↵<Button↵ android:id="@+id/btnNext"↵ android:layout_width="wrap_content"↵ android:layout_height="wrap_content"↵ android:layout_marginEnd="32dp"↵ android:layout_marginStart="32dp"↵ android:layout_marginTop="64dp"↵ android:text="@string/next"↵ android:textColor="@color/background_green"↵ android:textSize="18sp"↵ app:layout_constraintEnd_toEndOf="parent"↵ app:layout_constraintStart_toStartOf="parent"↵ app:layout_constraintTop_toBottomOf="@+id/textView3" />↵↵<TextView↵ android:id="@+id/textView3"↵ android:layout_width="0dp"↵ android:layout_height="wrap_content"↵ android:layout_marginEnd="8dp"↵ android:layout_marginStart="8dp"↵ android:layout_marginTop="20dp"↵ android:text="Welcome to My App"↵ android:textAlignment="center"↵ android:textColor="@android:color/white"↵ android:textSize="24sp"↵ app:layout_constraintEnd_toEndOf="parent"↵ app:layout_constraintStart_toStartOf="parent"↵ app:layout_constraintTop_toBottomOf="@+id/imageView4" />↵↵</android.support.constraint.ConstraintLayout>↵↵Im also using the latest version of ConstraintLayout↵compile 'com.android.support.constraint:constraint-layout:1.0.2'↵↵A:↵↵You need to add:↵↵android:gravity="center"↵↵to the TextView.↵This is the only certain way to center the text inside a TextView object or one of its subclasses.↵The android:textAlignment is not working in all the cases and as reported by this answer that it has problems in lower API levels. ↵↵
Values
Token Positive-pole strength wrong0.000 or0.000 I0.000 'm0.000 losing0.000 my0.026 mind0.077 .↵0.000 Here0.000 is0.000 the0.000 image0.000 ↵0.000 Here0.000 is0.004 the0.000 XML0.033 code0.037 ↵0.010 <?0.007 xml0.000 version0.000 ="0.000 10.000 .0.000 00.000 "0.000 encoding0.534 ="0.188 utf0.000 -0.818 80.036 "?>↵0.000 <0.017 android0.000 .support0.000 .constraint0.000 .Constraint0.000 Layout0.000 ↵0.043 xmlns0.000 -
0.77
# Copyright 2016 The Chromium Authors. All rights reserved.↵ …
All 101 tokens
# Copyright 2016 The Chromium Authors. All rights reserved.↵# Use of this source code is governed by a BSD-style license that can be↵# found in the LICENSE file.↵↵mojom = "//url/mojo/url.mojom"↵public_headers = [ "//url/gurl.h" ]↵traits_headers = [ "//url/mojo/url_gurl_struct_traits.h" ]↵deps = [↵ "//url",↵]↵type_mappings = [ "url.mojom.Url=GURL" ]↵
Values
Token Positive-pole strength #0.036 Copyright0.024 0.001 20.095 00.772 10.735 60.212 The0.000 Chromium0.000 Authors0.000 .0.000 All0.000 rights0.000 reserved0.000 .↵0.000 -
0.69
@comment $NetBSD: PLIST,v 1.5 2017/06/21 08: …
All 1107 tokens
@comment $NetBSD: PLIST,v 1.5 2017/06/21 08:28:43 markd Exp $↵share/texmf-dist/scripts/luaotfload/luaotfload-tool.lua↵share/texmf-dist/scripts/luaotfload/mkcharacters↵share/texmf-dist/scripts/luaotfload/mkglyphlist↵share/texmf-dist/scripts/luaotfload/mkimport↵share/texmf-dist/scripts/luaotfload/mkstatus↵share/texmf-dist/scripts/luaotfload/mktests↵share/texmf-dist/tex/luatex/luaotfload/fontloader-2017-02-11.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-basics-gen.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-basics-nod.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-basics.tex↵share/texmf-dist/tex/luatex/luaotfload/fontloader-data-con.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-afk.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-cff.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-cid.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-con.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-def.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-dsp.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-gbn.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-ini.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-lua.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-map.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-ocl.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-one.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-onr.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-osd.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-ota.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-otc.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-oti.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-otj.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-otl.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-oto.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-otr.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-ots.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-oup.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-tfm.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-font-ttf.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-fonts-demo-vf-1.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-fonts-enc.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-fonts-ext.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-fonts-syn.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-fonts.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-fonts.tex↵share/texmf-dist/tex/luatex/luaotfload/fontloader-l-boolean.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-l-file.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-l-function.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-l-io.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-l-lpeg.lua↵share/texmf-dist/tex/luatex/luaotfload/fontloader-l-lua.lua↵share
Values
Token Positive-pole strength @0.037 comment0.000 $0.000 Net0.000 BSD0.000 :0.000 PL0.022 IST0.000 ,v0.000 0.000 10.000 .0.050 50.000 0.176 20.000 00.200 10.413 70.695 /0.013 00.173 60.192 /0.045 20.064 10.017 0.000 00.005 80.000 :0.162 -
0.66
… the value of the select element under controller A into the function call in the select under controller B?↵Price.html view↵ <div class="col-sm-3" ng-controller="campCtrl"> ** …
All 748 tokens
Q:↵↵Binding value to select in angular js across 2 controllers↵↵Working with angularJS I am trying to figure out a way to bind the value of a select element under the scope of controller A to use it as an argument for an ng-click call [getQuizByCampID() Function] under the scope of controller B.↵My first idea was to use jquery, but I have read in the link below that using jquery is not recommended when starting with angularJS. ↵"Thinking in AngularJS" if I have a jQuery background?↵I also read in the link below that this is performed using ng-model, the only problem is that that the example provided is all under the same controller. ↵ and Binding value to input in Angular JS↵What is the angularJS way to get the value of the select element under controller A into the function call in the select under controller B?↵Price.html view↵ <div class="col-sm-3" ng-controller="campCtrl"> **Controller A** ↵ <select id="selCampID" class="form-control" ng-model="campInput" >↵ <option ng-repeat="camp in campaigns" value="{{camp.camp_id}}">{{camp.camp_name}}</option> ↵ </select>↵ </div>↵↵ <div class="col-sm-3" ng-controller="quizCtrl"> **Controller B**↵ <select ng-click="getQuizByCampID($('#selCampID').val())" class="form-control" ng-model="quizInput">↵ <option ng-controller="quizCtrl" ng-repeat="quiz in quizzesById" value="{{quiz.quiz_id}}">{{quiz.quiz_name}}</option> ↵ </select>↵ </div>↵↵App.js↵var app= angular.module('myApp', ['ngRoute']);↵app.config(['$routeProvider', function($routeProvider) {↵ $routeProvider.when('/price', {templateUrl: 'partials/price.html', controller: 'priceCtrl'});↵}]);↵↵$routeProvider.when('/price', {templateUrl: 'partials/price.html', controller: 'priceCtrl'});↵↵Quiz Controller↵'use strict';↵↵app.controller('quizCtrl', ['$scope','$http','loginService', function($scope,$http,loginService){↵$scope.txt='Quiz';↵$scope.logout=function(){↵ loginService.logout();↵}↵getQuiz(); // Load all available campaigns ↵function getQuiz(campID){ ↵ $http.post("js/ajax/getQuiz.php").success(function(data){↵ $scope.quizzes = data;↵ //console.log(data);↵ });↵};↵ $scope.getQuizByCampID = function (campid) {↵ alert(campid);↵$http.post("js/ajax/getQuiz.php?campid="+campid).success(function(data){↵ $scope.quizzesById = data;↵ $scope.QuizInput = "";↵ });↵ };↵↵ $scope.addQuiz = function (quizid, quizname, campid) { ↵ console.log(quizid + quizname + campid); ↵ $http.post("js/ajax/addQuiz.php?quizid="+quizid+"&quizname="+quizname+"&campid="+campid).success(function(data){↵↵ getQuiz();↵ $scope.QuizInput = "";↵});↵ };↵↵}])↵↵A:↵↵You should store the value in a service.↵example: ↵app.factory('SharedService', function() {↵ this.inputValue = null;↵↵ this.setInputValue = function(value) {↵ this.inputValue = value;↵ }↵↵ this.getInputValue = function() {↵ return this.inputValue;↵ }↵↵ return this;↵});↵↵Example on Plunkr↵Read: AngularJS Docs on services↵or check
Values
Token Positive-pole strength the0.000 value0.000 of0.000 the0.000 select0.000 element0.000 under0.034 controller0.000 A0.171 into0.094 the0.043 function0.027 call0.000 in0.070 the0.064 select0.009 under0.056 controller0.048 B0.063 ?↵0.000 Price0.029 .html0.129 view0.056 ↵0.067 0.000 <0.000 div0.000 class0.000 ="0.000 col0.000 -sm0.664 -0.242 30.000 "0.000 ng0.000 -controller0.036 ="0.000 camp0.000 Ctrl0.000 ">0.000 **0.000 -
0.65
… "Lut",↵ "Lun",↵ "Kas",↵ "Cis"↵ ],↵ "fullDate": "EEEE d MMMM y",↵ "longDate": "d MMM …
All 937 tokens
'use strict';↵angular.module("ngLocale", [], ["$provide", function($provide) {↵var PLURAL_CATEGORY = {ZERO: "zero", ONE: "one", TWO: "two", FEW: "few", MANY: "many", OTHER: "other"};↵function getDecimals(n) {↵ n = n + '';↵ var i = n.indexOf('.');↵ return (i == -1) ? 0 : n.length - i - 1;↵}↵↵function getVF(n, opt_precision) {↵ var v = opt_precision;↵↵ if (undefined === v) {↵ v = Math.min(getDecimals(n), 3);↵ }↵↵ var base = Math.pow(10, v);↵ var f = ((n * base) | 0) % base;↵ return {v: v, f: f};↵}↵↵$provide.value("$locale", {↵ "DATETIME_FORMATS": {↵ "AMPMS": [↵ "Dinda",↵ "Dilolo"↵ ],↵ "DAY": [↵ "Lumingu",↵ "Nkodya",↵ "Nd\u00e0ay\u00e0",↵ "Ndang\u00f9",↵ "Nj\u00f2wa",↵ "Ng\u00f2vya",↵ "Lubingu"↵ ],↵ "MONTH": [↵ "Ciongo",↵ "L\u00f9ishi",↵ "Lus\u00f2lo",↵ "M\u00f9uy\u00e0",↵ "Lum\u00f9ng\u00f9l\u00f9",↵ "Lufuimi",↵ "Kab\u00e0l\u00e0sh\u00ecp\u00f9",↵ "L\u00f9sh\u00eck\u00e0",↵ "Lutongolo",↵ "Lung\u00f9di",↵ "Kasw\u00e8k\u00e8s\u00e8",↵ "Cisw\u00e0"↵ ],↵ "SHORTDAY": [↵ "Lum",↵ "Nko",↵ "Ndy",↵ "Ndg",↵ "Njw",↵ "Ngv",↵ "Lub"↵ ],↵ "SHORTMONTH": [↵ "Cio",↵ "Lui",↵ "Lus",↵ "Muu",↵ "Lum",↵ "Luf",↵ "Kab",↵ "Lush",↵ "Lut",↵ "Lun",↵ "Kas",↵ "Cis"↵ ],↵ "fullDate": "EEEE d MMMM y",↵ "longDate": "d MMMM y",↵ "medium": "d MMM y HH:mm:ss",↵ "mediumDate": "d MMM y",↵ "mediumTime": "HH:mm:ss",↵ "short": "d/M/y HH:mm",↵ "shortDate": "d/M/y",↵ "shortTime": "HH:mm"↵ },↵ "NUMBER_FORMATS": {↵ "CURRENCY_SYM": "FrCD",↵ "DECIMAL_SEP": ",",↵ "GROUP_SEP": ".",↵ "PATTERNS": [↵ {↵ "gSize": 3,↵ "lgSize": 3,↵ "maxFrac": 3,↵ "minFrac": 0,↵ "minInt": 1,↵ "negPre": "-",↵ "negSuf": "",↵ "posPre": "",↵ "posSuf": ""↵ },↵ {↵ "gSize": 3,↵ "lgSize": 3,↵ "maxFrac": 2,↵ "minFrac": 2,↵ "minInt": 1,↵ "negPre": "-",↵ "negSuf": "\u00a4",↵ "posPre": "",↵ "posSuf": "\u00a4"↵ }↵ ]↵ },↵ "id": "lu-cd",↵ "pluralCat": function (n, opt_precision) { var i = n | 0; var vf = getVF(n, opt_precision); if (i == 1 && vf.v == 0) { return PLURAL_CATEGORY.ONE; } return PLURAL_CATEGORY.OTHER;}↵});↵}]);
Values
Token Positive-pole strength "0.067 L0.095 ut0.001 ",↵0.001 0.040 "0.034 L0.084 un0.073 ",↵0.005 0.000 "0.030 K0.088 as0.079 ",↵0.000 0.000 "0.052 C0.100 is0.068 "↵0.000 0.048 ],↵0.000 0.000 "0.000 full0.027 Date0.044 ":0.017 "0.031 EEEE0.099 d0.000 MMM0.250 M0.649 y0.000 ",↵0.055 0.000 "0.019 long0.000 Date0.000 ":0.042 "0.000 d0.000 MMM0.000 -
0.64
… -bg);
↵ background-image: url('../../images/overlay.png'), linear-gradient(0deg, rgba(0,0,0,0.1), rgba(0,0,0, …
All 469 tokens
/// ↵/// Massively by HTML5 UP ↵/// html5up.net | @ajlkn ↵/// Free for personal and commercial use under the CCA 3.0 license (html5up.net/license) ↵/// ↵ ↵/* Wrapper */ ↵ ↵ #wrapper { ↵ @include vendor('transition', 'opacity #{_duration(menu)} ease'); ↵ position: relative; ↵ z-index: 1; ↵ overflow: hidden; ↵ ↵ > .bg { ↵ position: absolute; ↵ top: 0; ↵ left: 0; ↵ width: 100%; ↵ height: 100%; ↵ background-color: _palette(wrapper-bg); ↵ background-image: url('../../images/overlay.png'), linear-gradient(0deg, rgba(0,0,0,0.1), rgba(0,0,0,0.1)), url('../../images/bg.jpg'); ↵ background-size: auto, auto, 100% auto; ↵ background-position: center, center, top center; ↵ background-repeat: repeat, no-repeat, no-repeat; ↵ background-attachment: scroll, scroll, scroll; ↵ z-index: -1; ↵ ↵ &.fixed { ↵ position: fixed; ↵ width: 100vw; ↵ height: 100vh; ↵ } ↵ } ↵ ↵ &.fade-in { ↵ &:before { ↵ @include vendor('pointer-events', 'none'); ↵ @include vendor('transition', 'opacity 1s ease-in-out'); ↵ @include vendor('transition-delay', '0.75s'); ↵ background: _palette(invert, bg); ↵ content: ''; ↵ display: block; ↵ height: 100%; ↵ left: 0; ↵ opacity: 0; ↵ position: fixed; ↵ top: 0; ↵ width: 100%; ↵ } ↵ ↵ body.is-loading & { ↵ &:before { ↵ opacity: 1; ↵ } ↵ } ↵ } ↵ ↵ @include orientation(portrait) { ↵ > .bg { ↵ background-size: auto, auto, auto 175%; ↵ } ↵ } ↵ }
Values
Token Positive-pole strength -bg0.000 ); ↵0.000 0.000 background0.000 -image0.002 :0.038 0.000 url0.002 ('../../0.000 images0.000 /0.000 overlay0.000 .png0.000 '),0.000 0.036 linear0.000 -gradient0.102 (0.187 00.197 deg0.000 ,0.003 rgba0.080 (0.139 00.009 ,0.233 00.000 ,0.499 00.000 ,0.158 00.008 .0.641 10.185 ),0.063 rgba0.013 (0.005 00.005 ,0.036 00.000 ,0.127 00.000 ,0.035 -
0.62
… .dao.WeatherDataHelper;↵import tk.woppo.sunday.dao.WeatherTodayDataHelper;↵↵/**↵ * Created by Ho on 2014/7/4.↵ */↵public class WeatherToday …
All 417 tokens
package tk.woppo.sunday.model;↵↵import android.database.Cursor;↵↵import com.google.gson.Gson;↵import com.google.gson.annotations.SerializedName;↵↵import java.util.HashMap;↵↵import tk.woppo.sunday.dao.WeatherDataHelper;↵import tk.woppo.sunday.dao.WeatherTodayDataHelper;↵↵/**↵ * Created by Ho on 2014/7/4.↵ */↵public class WeatherTodayModel extends BaseModel {↵↵ private static final HashMap<String, WeatherTodayModel> CACHE = new HashMap<String, WeatherTodayModel>();↵↵ /** ���市ID */↵ @SerializedName("cityid")↵ public String id;↵↵ /** ���市名称 */↵ @SerializedName("city")↵ public String cityName;↵↵ /** ��度 */↵ public String temp;↵↵ /** ��气 */↵ public String weather;↵↵ /** ���向 */↵ @SerializedName("WD")↵ public String wind;↵↵ /** ���力 */↵ @SerializedName("WS")↵ public String ws;↵↵ /** ���度 */↵ @SerializedName("SD")↵ public String sd;↵↵ /** 发布时间 */↵ public String time;↵↵ private static void addToCache(WeatherTodayModel model) {↵ CACHE.put(model.id, model);↵ }↵↵ private static WeatherTodayModel getFromCache(String id) {↵ return CACHE.get(id);↵ }↵↵ public static WeatherTodayModel fromJson(String json) {↵ return new Gson().fromJson(json, WeatherTodayModel.class);↵ }↵↵ public static WeatherTodayModel fromCursor(Cursor cursor) {↵ String id = cursor.getString(cursor.getColumnIndex(WeatherDataHelper.WeatherDBInfo.ID));↵ WeatherTodayModel model = getFromCache(id);↵ if (model != null) {↵ return model;↵ }↵ model = new Gson().fromJson(cursor.getString(cursor.getColumnIndex(WeatherTodayDataHelper.WeatherTodayDBInfo.JSON)), WeatherTodayModel.class);↵ addToCache(model);↵ return model;↵ }↵↵ public static class WeatherTodayRequestData {↵ public WeatherTodayModel weatherinfo;↵ }↵}↵
Values
Token Positive-pole strength .dao0.000 .We0.000 ather0.000 Data0.000 Helper0.000 ;↵0.000 import0.017 tk0.027 .w0.033 opp0.057 o0.000 .s0.000 unday0.000 .dao0.000 .We0.000 ather0.000 Today0.000 Data0.000 Helper0.033 ;↵↵0.016 /**↵0.000 *0.000 Created0.000 by0.058 Ho0.000 on0.314 0.119 20.013 00.049 10.175 40.618 /0.081 70.111 /0.000 40.044 .↵0.393 */↵0.008 public0.000 class0.000 Weather0.000 Today0.000 -
0.61
… with local one.↵import java.io.File;↵import java.io.IOException;↵import java.net.SocketException;↵import java.util.Scanner;↵↵import org.apache.commons.io.FileUtils;↵import org.apache.commons.net.ftp.F …
All 591 tokens
Q:↵↵How to check if file exist when downloading from FTP↵↵I'm downloading from FTP server and I don't know exactly how to check if file already exist. What I want to do is that I retrieve filname from FTP server and then compare it with all files in folder. If file already exists then it compares next FTP filename with all files in folder and so on. ↵I already did comparison and it's working if all files from folder have same name as files on FTP server but if I add some older file then it downloads all files once again and I don't want that. ↵Here is my scratch code:↵String[] names = client.listNames();↵ File folder = new File("c:\\test\\RTR_ZIP\\");↵ String[] filename = folder.list();↵↵ for (;i<names.length;i++) {↵ name = names[i];↵↵ exists=false;↵↵ if (name.contains(".zip")) {↵↵ if (filename.length == 0) {↵ new_file = new FileOutputStream("C:\\test\\RTR_ZIP\\" + name);↵ client.retrieveFile(name, new_file);↵ j++;↵ exists=true;↵ } else {↵ for (;k<filename.length;k++) {↵ name = names[i];↵ i++;↵ name1=filename[k];↵ // CHECK IF FILE EXISTS↵ if (!name.equals(name1)) {↵ new_file = new FileOutputStream("C:\\test\\RTR_ZIP\\" + name);↵ client.retrieveFile(name, new_file);↵ j++;↵ exists=true;↵ } ↵ }↵ }//else↵ }//if contains .zip↵ }//for↵↵Thanks in advance. ↵↵A:↵↵If your ftp server supports XCRC command it could be possible to compare checksum (CRC32) of local and remote file.↵You could iterate all files in the folder and compare its crc with local one.↵import java.io.File;↵import java.io.IOException;↵import java.net.SocketException;↵import java.util.Scanner;↵↵import org.apache.commons.io.FileUtils;↵import org.apache.commons.net.ftp.FTPClient;↵↵public class DownloadFile {↵↵ private FTPClient client = new FTPClient();↵↵ public void connect() throws SocketException, IOException {↵ client.connect("127.0.0.1");↵ client.login("user", "password");↵ }↵↵ public boolean hasXCRCSupport() throws IOException {↵ client.sendCommand("feat");↵ String response = client.getReplyString();↵ Scanner scanner = new Scanner(response);↵ while(scanner.hasNextLine()) {↵ String line = scanner.nextLine();↵ if(line.contains("XCRC")) {↵ return true;↵ }↵ }↵ return false;↵ }↵↵ public boolean isSameFile() throws IOException {↵ if(hasXCRCSupport()) {↵ File file = new File("D:/test.txt");↵ String localCRC = Integer.toHexString((int) FileUtils.checksumCRC32(file))
Values
Token Positive-pole strength with0.000 local0.000 one0.000 .↵0.000 import0.056 java0.026 .io0.017 .File0.364 ;↵0.000 import0.000 java0.095 .io0.026 .IOException0.412 ;↵0.007 import0.000 java0.151 .net0.034 .Socket0.180 Exception0.518 ;↵0.128 import0.000 java0.150 .util0.113 .Scanner0.125 ;↵↵0.000 import0.000 org0.036 .apache0.239 .commons0.144 .io0.280 .File0.608 Utils0.273 ;↵0.117 import0.000 org0.039 .apache0.182 .commons0.108 .net0.000 .0.000 ftp0.000 .F0.000 -
0.61
… function drawStar (graphics, cx, cy, spikes, outerRadius, innerRadius, color, lineColor)↵{↵ var rot = Math.PI / 2 * 3;↵ var x = …
All 413 tokens
var config = {↵ type: Phaser.AUTO,↵ parent: 'phaser-example',↵ width: 800,↵ height: 600,↵ scene: {↵ create: create↵ },↵};↵↵var game = new Phaser.Game(config);↵↵function create() {↵↵ var graphics = this.add.graphics();↵↵ drawStar(graphics, 100, 300, 4, 50, 50 / 2, 0xffff00, 0xff0000);↵ drawStar(graphics, 400, 300, 5, 100, 100 / 2, 0xffff00, 0xff0000);↵ drawStar(graphics, 700, 300, 6, 50, 50 / 2, 0xffff00, 0xff0000);↵}↵↵function drawStar (graphics, cx, cy, spikes, outerRadius, innerRadius, color, lineColor)↵{↵ var rot = Math.PI / 2 * 3;↵ var x = cx;↵ var y = cy;↵ var step = Math.PI / spikes;↵↵ graphics.lineStyle(4, lineColor, 1);↵ graphics.fillStyle(color, 1);↵ graphics.beginPath();↵ graphics.moveTo(cx, cy - outerRadius);↵↵ for (i = 0; i < spikes; i++)↵ {↵ x = cx + Math.cos(rot) * outerRadius;↵ y = cy + Math.sin(rot) * outerRadius;↵ graphics.lineTo(x, y);↵ rot += step;↵↵ x = cx + Math.cos(rot) * innerRadius;↵ y = cy + Math.sin(rot) * innerRadius;↵ graphics.lineTo(x, y);↵ rot += step;↵ }↵↵ graphics.lineTo(cx, cy - outerRadius);↵ graphics.closePath();↵ graphics.fillPath();↵ graphics.strokePath();↵}↵
Values
Token Positive-pole strength function0.035 draw0.022 Star0.207 (0.000 graphics0.001 ,0.058 cx0.000 ,0.000 cy0.000 ,0.000 spikes0.000 ,0.000 outer0.000 Radius0.000 ,0.000 inner0.000 Radius0.000 ,0.000 color0.000 ,0.000 line0.000 Color0.000 )↵0.000 {↵0.061 0.000 var0.000 rot0.000 =0.000 Math0.000 .PI0.313 /0.607 0.544 20.064 *0.138 0.110 30.000 ;↵0.000 0.000 var0.000 x0.000 =0.000
Read more
Each token is shaded by positive-pole strength, as a fraction of the neuron's max activation. Each window shows up to 30 tokens before the peak and 10 after it.
Activation and mechanism
Activation distribution
Positive-pole strength per token; bar height is log(1 + count).
Mechanism
Claimed retrospective: responds to tokens already in context.
Input attribution
- 0 back
- 26%
- 1 back
- 30%
- 2–4 back
- 30%
- 5–16 back
- 15%
- 17–64 back
- 0%
- 65+ back
- 0%
- #1 (not converged) at
_length:.FloatField-17 -0.78the-92 -0.70get-67 -0.52from-33 0.46't-68 -0.44 - #2 (not converged) at
files:static-1 0.54files0 0.37load-2 0.25that-20 0.20{%-3 0.18 - #3 at
2:0-1 0.682-2 0.57Copyright-9 -0.330-4 0.182-7 -0.16 - #4 (not converged) at
-:utf-1 2.68-0 -0.87encoding-3 -0.48="-2 0.41: -85 -0.36 - #5 at
0:00 0.582-1 0.38Copyright-3 0.20-2 -0.15#-4 0.00
Shares of the gap to <|endoftext|> at every position but the first · converged on 2 of 5 · mean 2.2 tokens back ·
agreement with replacing one token at a time ρ = 0.73 · reported, not gated
Vocabulary projection
The tokens that this unit's output raises and lowers most.
Jacobian lens
Logit lens
Values
| # | Jacobian lens promotes | suppresses | Logit lens promotes | suppresses | ||||
|---|---|---|---|---|---|---|---|---|
| 1 | “[ |
+4.81 | "\
|
-5.18 | descent |
+4.15 | naire |
-4.87 |
| 2 | —including |
+4.72 | "
|
-4.89 | recall |
+4.13 | ?>' |
-4.53 |
| 3 | —which |
+4.38 | \
|
-4.72 | 出租 |
+4.08 | galement |
-4.48 |
| 4 | evolves |
+4.37 | "+
|
-4.65 | including |
+4.07 | gratuits |
-4.43 |
| 5 | 、“ |
+4.28 | "
|
-4.64 | orgeous |
+3.97 | naires |
-4.43 |
| 6 | ,— |
+4.26 | '
|
-4.54 | developmental |
+3.92 | esco |
-4.32 |
| 7 | variants |
+4.21 | ";
|
-4.53 | AssemblyCopyright |
+3.86 | *>* |
-4.27 |
| 8 | dynamics |
+4.14 | '
|
-4.47 | -div |
+3.85 | .dex |
-4.25 |
| 9 | .— |
+4.09 | 打败 |
-4.38 | Carolyn |
+3.80 | traî |
-4.24 |
| 10 | .
|
+4.08 | 临 |
-4.38 | sing |
+3.78 | ayne |
-4.22 |
Top-10 overlap 0% · cos(w, J·w) 0.15 · kurtosis 3.4 (Jacobian) / 3.0 (logit) · 100 prompts
Read more
The output direction is read through the final norm and the unembedding. The Jacobian lens first carries it to the last layer. Bar length is the token's z-score over the vocabulary, and ␣ marks a space. A kurtosis near 3 means no specific set of tokens.
Patchscope
The model's own description of this unit's output, with no examples.
Read more
The unit's direction replaces the residual stream after the named layer, at the ? of each prompt. It is scaled to each multiple of the norm it replaces, and the model continues greedily. The control injects a random direction, so text that both rows share comes from the prompt. Read after the proposer answered, and shown to neither agent. Reported, not gated.
| Prompt | Layer | ×1 | ×2 | ×4 | |
|---|---|---|---|---|---|
| category | 2 | unit | : : : : : : : : : : : : | noun | politics |
| control | period | emotion | animal | ||
| category | 12 | unit | person | person | person |
| control | animal | sport | sport | ||
| meaning | 2 | unit | "to be" or "to be able to" ( | to indicate the meaning of a word. For example, the | to be determined by the context in which it is used. |
| control | to increase the value of something. It is used to describe | to be used in a positive way. It is not to | "to be the subject of a verb, to be the | ||
| meaning | 12 | unit | that the word is not a word. The word "word | "the same as" or "the same as this". | that the word is not a word. The word "word |
| control | "to be" or "to have" in the sentence | "to be" or "to be able to" in | "to be" or "to be able to" in |
Hover a prompt's name for its text.
Wiring
The units that write most directly into this pole (upstream) and read most directly from it (downstream). See its circuit.
Read more
"Directly" means along the residual stream, through no other unit. Linked units have pages in the registry. Reported, not gated.
From activations. Averaged over this pole's peak on 12 of the review's prompts where it fired. Upstream: the first-order change in its strength when a unit's direct write is removed (+ excites). Downstream: the change in a later unit when this pole's write is removed from that unit's input alone (one of Q, K or V for a head).
From activations
Upstream neurons
| L6/N459 | +0.119 | |
| L9/N565 | -0.0684 | |
| L5/N3934 | +0.063 | |
| L5/N1541 | +0.0527 | |
| L7/N2523 | +0.0497 | |
| L6/N1590 | -0.0476 | |
| L4/N4763 | +0.0349 | |
| L6/N484 | -0.0346 | |
| L6/N3654 | +0.0342 | |
| L11/N1911 | -0.0332 |
Upstream heads
| L8/H3 | -0.228 | |
| L8/H7 | +0.213 | |
| L12/H8 | +0.0812 | |
| L12/H0 | -0.0785 | |
| L12/H12 | +0.0682 | |
| L7/H4 | -0.0646 | |
| L9/H4 | +0.0528 | |
| L12/H3 | +0.0504 | |
| L11/H1 | -0.0503 | |
| L5/H9 | -0.0491 |
Downstream neurons
| L23/N4144 | -0.148 | |
| L23/N1396 | +0.115 | |
| L23/N3935 | +0.102 | |
| L23/N2607 | -0.0996 | |
| L23/N4861 | +0.0963 | |
| L23/N1121 | -0.078 | |
| L23/N2228 | +0.0746 | |
| L21/N2930 | -0.0736 | |
| L23/N2505 | +0.0727 | |
| L14/N320 | +0.0718 |
Downstream heads
| L14/H1 | v | +0.0725 |
| L13/H3 | v | +0.0529 |
| L23/H1 | v | +0.05 |
| L14/H7 | q | +0.0475 |
| L14/H10 | v | +0.0403 |
| L16/H10 | q | +0.0396 |
| L18/H11 | q | +0.0362 |
| L17/H1 | q | +0.0349 |
| L14/H12 | q | +0.0319 |
| L15/H1 | v | +0.0316 |
Covariance and confounds
Confounds
- Token identity R²
- 0.26
- Position R²
- 0.01
- Frequency r
- 0.11
- Best trivial baseline
- never active · 0.67
- Hypothesis
- 0.83 ✓
-sm.File Katliving neither encoding dep(max IBipientsWho neuro
Co-activating neuron poles
| Pole | Lift ≥ | Both | ρ | r |
|---|---|---|---|---|
| N1125+ | 6.6 | 66 | +0.00 | +0.06 |
| N3050+ | 6.4 | 65 | +0.01 | +0.03 |
| N4849− | 5.4 | 56 | -0.00 | -0.00 |
| N400− | 5.0 | 52 | +0.11 | -0.08 |
| N4601+ | 4.8 | 50 | +0.01 | +0.06 |
| N2792+ | 4.8 | 50 | -0.00 | +0.00 |
| N876− | 4.7 | 49 | +0.04 | -0.05 |
| N3678+ | 4.7 | 49 | -0.03 | +0.01 |
| N3948+ | 4.6 | 48 | +0.11 | +0.09 |
| N4463+ | 4.5 | 47 | +0.04 | +0.03 |
Read more
Ranked by the 95% lower bound of co-activation lift: how much more often a pole fires when this one does, with chance coincidences discounted. ρ ranks the values, so heavy tails don't sway it.
Joint ablation
- Partners
- N1125, N3050, N4849
- KL pole alone
- 5.96e-06
- KL partners
- 2.05e-04
- KL together
- 2.13e-04
- Redundancy ratio
- 1.33
The partners don't change the pole's effect much.
Run details
- Submitted by
- deepseek-flash
- Reviewed by
- deepseek-flash (same model as the proposer: not an independent review)
- Reviewed at
- 2026-10-31 00:04 UTC
- Max activation
- 1.0759
- Selection
- manual
- Corpus
- corpus.jsonl · 199,896 tokens · seeded sample of 477/500 docs (≤ 200,000 tokens, seed 0) · source NeelNanda/pile-10k@127bfedc (data/*.parquet, first 500 docs) (inferred) · licence bigscience-bloom-rail-1.0
- Model revision
- 060db6499f32 · float32
- Ran on
- scan mps:0 · review cpu
- Run cost
- 15.7 min (slowest: probe_measurement, 7.0 min)