Skip to content

Instantly share code, notes, and snippets.

View takanakahiko's full-sized avatar
😸
😸

takanakahiko

😸
😸
View GitHub Profile
@takanakahiko
takanakahiko / sample.rq
Created June 1, 2020 18:36
VTuberの所属一覧
prefix vlueprint: <https://vlueprint.org/schema/>
prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#>
select ?LABEL ?ORGLABEL {
?uri rdf:type vlueprint:VirtualBeing.
?uri rdfs:label ?LABEL.
?uri vlueprint:belongTo ?orgUri.
?orgUri rdfs:label ?ORGLABEL.
}
@takanakahiko
takanakahiko / sample.rq
Created June 1, 2020 18:34
VIrtual住人のTwitter一覧
prefix vlueprint: <https://vlueprint.org/schema/>
prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#>
select ?LABEL ?TWITTER {
?uri rdf:type vlueprint:VirtualBeing.
?uri rdfs:label ?LABEL.
?uri vlueprint:twitterAccount ?TWITTER.
}
@takanakahiko
takanakahiko / sample.rq
Created June 1, 2020 18:22
月ノ美兎のyoutubeChannelIdを取得する
prefix vlueprint: <https://vlueprint.org/schema/>
prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#>
select ?YOUTTUBE {
?uri vlueprint:youtubeChannelId ?YOUTTUBE.
?uri rdfs:label "月ノ美兎".
}
@takanakahiko
takanakahiko / main.js
Created March 15, 2020 02:28
MEMORIES FOR FUTURE をループするやつ
// これを全てコピーしてjavascriptコンソールに貼り付けて実行します
setInterval(() => {
const video = document.getElementById("player-embed-videoid_html5_api");
if(video.currentTime>1088) video.currentTime=954;
}, 1000);
@takanakahiko
takanakahiko / main.js
Created March 15, 2020 02:28
MEMORIES FOR FUTURE をループするやつ
// これを全てコピーしてjavascriptコンソールに貼り付けて実行します
setInterval(() => {
const video = document.getElementById("player-embed-videoid_html5_api");
if(video.currentTime>1088) video.currentTime=954;
}, 1000);
@takanakahiko
takanakahiko / Code.gs
Created August 22, 2019 18:34
ふりがなGAS
var nsDefault = XmlService.getNamespace("urn:yahoo:jp:jlp:FuriganaService");
function parseXml() {
var url = 'http://jlp.yahooapis.jp/FuriganaService/V1/furigana';
var params = [
'appid=XXXXXXXXXXXXXXXXXXXX',
'sentence=' + encodeURIComponent('初音ミクさんを忘れないでください'),
'grade=1'
]
var xml = UrlFetchApp.fetch(url + '?' + params.join('&') ).getContentText();
# coding: utf-8
import requests
import xmltodict
import fileinput
def getAccess(url, **option):
r = requests.get(url, params=option)
return r.text
@takanakahiko
takanakahiko / sample.rq
Created August 6, 2019 12:20
アイマスとプリティーシリーズの共通声優を抽出
PREFIX prism: <https://prismdb.takanakahiko.me/prism-schema.ttl#>
PREFIX imas: <https://sparql.crssnky.xyz/imasrdf/URIs/imas-schema.ttl#>
PREFIX toaru: <https://metadata.moe/toaru-sparql/elements/>
SELECT distinct (?prism_cv as ?cv) {
service<https://sparql.crssnky.xyz/spql/imas/query>{
?imas imas:cv ?imas_cv.
}
?prism prism:cv ?prism_cv.
filter((str(?prism_cv)=str(?imas_cv)))
}
@takanakahiko
takanakahiko / sample.rq
Last active January 2, 2020 07:00
そらみスマイルのライブ一覧
PREFIX prism: <https://prismdb.takanakahiko.me/prism-schema.ttl#>
SELECT ?n ?st ?title
WHERE {
?live a prism:Live;
prism:performer "solami_smile";
prism:songPerformed/prism:name ?title;
prism:liveOfEpisode ?ep.
?ep a prism:Episode;
prism:話数 ?n;
We can make this file beautiful and searchable if this error is corrected: It looks like row 5 should actually have 1 column, instead of 3 in line 4.
a: unk
b: tnk
c: mnk
---
a,b,c
1,2,3
1,2,3