import fetch from "isomorphic-unfetch";
const translateToSQL = async (query, apiKey, tableSchema = "") => {
// Validate inputs
if (!query || !apiKey) {
throw new Error("Missing query or API key.");
}
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"Make": { | |
"value": "Apple", | |
"attributes": {}, | |
"description": "Apple" | |
}, | |
"Model": { | |
"value": "iPhone 13", | |
"attributes": {}, | |
"description": "iPhone 13" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extension CameraManagerPhotoOutput: @preconcurrency AVCapturePhotoCaptureDelegate { | |
func photoOutput(_ output: AVCapturePhotoOutput, didFinishProcessingPhoto photo: AVCapturePhoto, error: (any Error)?) { | |
guard let imageData = photo.fileDataRepresentation(), | |
let ciImage = CIImage(data: imageData) | |
else { return } | |
// Retrieve metadata from AVCapturePhoto | |
var metadata = photo.metadata | |
// Process the CIImage with filters |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extension CameraManagerPhotoOutput: @preconcurrency AVCapturePhotoCaptureDelegate { | |
func photoOutput(_ output: AVCapturePhotoOutput, didFinishProcessingPhoto photo: AVCapturePhoto, error: (any Error)?) { | |
guard let imageData = photo.fileDataRepresentation(), | |
let ciImage = CIImage(data: imageData) | |
else { return } | |
// Retrieve metadata from AVCapturePhoto | |
var metadata = photo.metadata | |
// Process the CIImage with filters |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extension CameraManagerPhotoOutput: @preconcurrency AVCapturePhotoCaptureDelegate { | |
func photoOutput(_ output: AVCapturePhotoOutput, didFinishProcessingPhoto photo: AVCapturePhoto, error: (any Error)?) { | |
guard let imageData = photo.fileDataRepresentation(), | |
let ciImage = CIImage(data: imageData) | |
else { return } | |
// Retrieve metadata from AVCapturePhoto | |
var metadata = photo.metadata | |
// Process the CIImage with filters |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ExifTool Version Number : 13.00 | |
File Name : sunrise.png | |
Directory : tmp | |
File Size : 12 MB | |
File Modification Date/Time : 2024:12:07 17:37:18+01:00 | |
File Access Date/Time : 2024:12:08 17:24:33+01:00 | |
File Inode Change Date/Time : 2024:12:08 12:55:19+01:00 | |
File Permissions : -rw-r--r-- | |
File Type : PNG | |
File Type Extension : png |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: UNLICENSED | |
pragma solidity ^0.8.20; | |
library IpfsCid { | |
bytes internal constant BASE32_ALPHABET = "abcdefghijklmnopqrstuvwxyz234567"; | |
/// @notice Converts a CID string to a `bytes32` hash. | |
/// @param cidString The Base32-encoded CID string (e.g., "bafy..."). | |
/// @return hash The `bytes32` representation of the multihash digest. | |
function cidToHash(string memory cidString) internal pure returns (bytes32) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require "bundler/inline" | |
require 'benchmark' | |
gemfile(true) do | |
source "https://rubygems.org/" | |
gem "ostruct" | |
gem "rails" | |
gem "sqlite3" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Timing is on. | |
id | atxuid | hash | events |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Timing is on. | |
id | created_at | updated_at | user_id | ownership_pending | owner_address | name | parent_id | node | resolver | resolution | registry_type | recent_event_id | reverse | logical_owner_address | tld_id | expires_at | token_type | permissions_bitmask | controller_address | primary_registry | |
---------+----------------------------+----------------------------+---------+-------------------+---------------+------+-----------+--------------------------------------------------------------------+----------+------------+---------------+-----------------+---------+-----------------------+--------+------------+------------+---------------------+--------------------+------------------ | |
1188769 | 2020-03-24 17:27:08.019717 | 2020-11-20 15:27:42.739649 | | f | | . | | 0x0000000000000000000000000000000000000000000000000000000000000000 | | {} | |
NewerOlder