iOSåãã«XCFrameworkãä½æããç½²åããæé
ãã®è¨äºã§ã¯XCFrameworkãä½æããç½²å(ã³ã¼ãç½²å)ãè¡ãæé ã解説ãã¾ãã 解説åã«ã¾ããè¨äºå ã«åºã¦ããç¨èªã®è§£èª¬ãæ¸ãã¦ããã¾ããç¥ããªãç¨èªãåºã¦ãããããã«æ»ã£ã¦ãã¦ç¢ºèªãã¦ä¸ããã
ç¨èªè§£èª¬
Archive
é å¸ãã¹ãã¢ã«å ¬éæã«å¿ è¦ãªå®è¡å¯è½ãã¡ã¤ã«ãã¢ã»ãããã¡ã¿ãã¼ã¿ãªã©ã®ãªã½ã¼ã¹ãBundleåãããã®ã
Bundle(ãã³ãã«)
æ¨æºåãããé層æ§é ãæã¤ãã£ã¬ã¯ããªã«ãªã½ã¼ã¹ãã¾ã¨ãããã®ãé常ã¯1ã¤ã®ãã¡ã¤ã«ã®æ§ã«æ±ããããå³ã¯ãªãã¯ã¡ãã¥ã¼ãããããã±ã¼ã¸ã®å 容ã表示ããé¸æããã¨ãã£ã¬ã¯ããªã«å«ã¾ããå 容ã確èªã§ããã
åèæ å ±ï¼Placing Content in a Bundle | Apple Developer Documentation
Framework
Dynamic shared library(åçå ±æã©ã¤ãã©ãª)ãStatic Library(éçã©ã¤ãã©ãª)ãã¢ã»ãããã¡ã¿ãã¼ã¿ãªã©ãBundleåãããã®ã
Dynamic shared library(åçå ±æã©ã¤ãã©ãª)
å®è¡æã«ã¢ããªããå©ç¨ããå½¢å¼ã®ã©ã¤ãã©ãªãè¤æ°ã®ã¢ããªããåæã«å©ç¨ããäºãå¯è½ã§ããçºãã¡ã¢ãªãç¯ç´ã§ããã¨ããå©ç¹ãæããã¾ããå¿ è¦ã«ãªã£ãæç¹ã§ãã¼ããããçºã«èµ·åæã«å¿ è¦ã«ã¡ã¢ãªéãæãããããªã©ã®å©ç¹ãæãã¾ãã
Static Library(éçã©ã¤ãã©ãª)
ã¢ããªã®ãã«ãæã«ã¢ããªå ã«åãè¾¼ã¾ããå½¢å¼ã®ã©ã¤ãã©ãªã
ç½²å
ãã®ãã¡ã¤ã«ãXCFrameworkã«å¯¾ãã¦ã以ä¸ã®äºãä¿è¨¼ããä»çµã¿ã
- ç½²åãããæç¹ããå¤æ´ãè¡ããã¦ããªã
- å¶ä½è ã¯ç½²åãã人ã§ãã
å¶ä½è ãç½²åå¦çãè¡ãäºã§ç½²åæ¸ã¿ã®ãã¡ã¤ã«ãXCFrameworkãä½æããäºãã§ãã¾ãã
XCFrameworkãä½æ
ã¾ãã¯Xcodeã§æ®éã«iOSã®Frameworkãä½æãã¾ãã
â»Frameworkã®ä½ææ¹æ³ã«ã¤ãã¦ã¯å¥éæ¤ç´¢ãã¦ä¸ããã
Frameworkãä½æããæã«ã¯Xcodeããã¸ã§ã¯ãã®Build Settingsã¿ãã§ä»¥ä¸ãã®ãæ¤ç´¢ãã¦è¨å®ãå¤æ´ãã¦ä¸ããã
- Build Libraries for DistributionãYes
- Skip InstallãNo
Frameworkã®Xcodeããã¸ã§ã¯ãã®æºåã§ãããã¿ã¼ããã«ãéãã.xcodeprojãã¡ã¤ã«ããããã£ã¬ã¯ããªã¸ç§»åãã¾ãã
ãã£ã¬ã¯ããªã§ä»¥ä¸ã®ã³ãã³ããå®è¡ããã¨iOSç°å¢åãã®archiveãä½æããã¾ãã
ä¾) TestFrameworkã¨ããããã¸ã§ã¯ãã®å ´å
xcodebuild archive \ -project TestFramework.xcodeproj \ -scheme TestFramework \ -destination "generic/platform=iOS" \ -archivePath "archives/TestFramework-iOS"
-projectã§Xcodeã®ããã¸ã§ã¯ãã®ãã¹ãæå®ã-archivePathã§archiveã®çæå ã®ãã¹ãæå®ãã¾ãã
ç¶ãã¦iOSã·ãã¥ã¬ã¼ã¿ç°å¢åãã«ä½æãã¾ããã³ãã³ãã¯ãã¡ãã
xcodebuild archive \ -project TestFramework.xcodeproj \ -scheme TestFramework \ -destination "generic/platform=iOS Simulator" \ -archivePath "archives/TestFramework-iOS_Simulator"
ããã§iOSåãã¨iOSã·ãã¥ã¬ã¼ã¿åãã®archiveãä½æã§ãã¾ããã
次ã«ä»¥ä¸ã®ã³ãã³ãã§2ã¤ã®archiveããXCFrameworkãä½æãã¾ãã
xcodebuild -create-xcframework \ -archive archives/TestFramework-iOS.xcarchive -framework TestFramework.framework \ -archive archives/TestFramework-iOS_Simulator.xcarchive -framework TestFramework.framework \ -output xcframeworks/TestFramework.xcframework
-archiveã§æå®ããarchiveã®ä¸ã®å«ã¾ãã¦ããã©ã®Frameworkã使ç¨ãããã-frameworkã§æå®ãã¾ãã-outputã§æå®ãããã¹ã«XCFrameworkãçæããã¾ãã
ããã§No 'swiftinterface' files found within '(ããã«TestFramework.swiftmoduleã®ãã¹)'
ã¨ããã¨ã©ã¼ã表示ãããæã«ã¯Frameworkä½ææã®è¨å®ã¨ãã¦è¨è¿°ããBuild Libraries for DistributionãYes
ãè¡ããã¦ããã確èªãã¦ä¸ããã
error: the path does not point to a valid framework: (ããã«TestFramework.frameworkã®ãã¹)
ã¨ããã¨ã©ã¼ã表示ãããæã«ã¯Skip InstallãNo
ãè¡ããã¦ããã確èªãã¦ä¸ããã
ãããFrameworkã§ã¯ãªãã.aãã¡ã¤ã«(Static Libraryãã¡ã¤ã«)ããXCFrameworkãä½æãããå ´åã«ã¯-frameworkã®ä»£ããã«-libraryã§.aãã¡ã¤ã«ã®ãã¹ã-headersã§ããããã¡ã¤ã«ã®ãã£ã¬ã¯ããªãæå®ãã¾ãã
(ã³ãã³ãä¾)
xcodebuild -create-xcframework -library products/iOS/usr/local/lib/libMyLibrary.a -headers products/iOS/usr/local/include -library products/iOS_Simulator/usr/local/lib/libMyLibrary.a -headers products/iOS/usr/local/include -output xcframeworks/MyLibrary.xcframework
ç½²å
ç½²åã¯Apple Developer Programã®IDããããã¯èªå·±ç½²å証ææ¸ã§è¡ãã¾ãã
ããã§ã¯Apple Developer Programã®IDã§ç½²åããæ¹æ³ã解説ãã¾ãã
Apple Distributionãã¾ã ä½æãã¦ããªãå ´åã«ã¯ä½æãå¿ è¦ã§ãã
â»Apple Distributionã®ä½ææ¹æ³ã«ã¤ãã¦ã¯å¥éæ¤ç´¢ãã¦ä¸ããã
Apple Distributionãä½æããKeychain(ããã¼ãã§ã¼ã³ã¢ã¯ã»ã¹ãã¢ããª)ã«è¿½å æ¸ã¿ã§æãã°ä»¥ä¸ã®æ§ãªè¨¼ææ¸ãè¦ã¤ããã¯ãã§ãã
ãã®ãApple Distribution: ãã§å§ã¾ãè¡ã®æååã¯ç½²åãè¡ãæã«å¿ è¦ãªã®ã§ã¡ã¢ãã¦ããã¦ä¸ããã
ç½²åãè¡ã
ã¿ã¼ããã«ã§ä»¥ä¸ã®ã³ãã³ããå®è¡ããã¨XCFrameworkã«ç½²åãè¡ããã¾ãã
codesign \ --timestamp \ -s "Apple Distribution: XXXXX (YYYYYYYYYY)" xcframeworks/TestFramework.xcframework
--timestampã§ç½²åæå»ã®èªè¨¼ãè¦æ±ãã¾ãã-sã§Appple Distributionã®æ å ±ãè¨è¼ãã¾ããå ã»ã©ã¡ã¢ãã¦ããApple Distribution:ããå§ã¾ãæååãè¨è¼ãã¦ä¸ãããæå¾ã«ç½²åãè¡ãXCFrameworkã®ãã¹ãæå®ãã¾ãã
ããã§XCFrameworkã®ä½æã¨ç½²åã®ä½æ¥ãçµããã¾ããã
ç½²åç¶æ³ã®ç¢ºèª
ã¾ãç°¡åãªç¢ºèªæ¹æ³ã¨ãã¦ã¯XCFrameworkã®ä¸ã«_CodeSignatureã¨ãããã£ã¬ã¯ããªãåå¨ãããã§ç¢ºèªã§ãã¾ãããã®ãã£ã¬ã¯ããªãåå¨ããå ´åã«ã¯ç½²åæ¸ã¿ã§ãã
Xcodeããã¸ã§ã¯ãã«XCFrameworkã追å æ¸ã¿ã®å ´åã«ã¯XCFrameworkãé¸æããç¶æ ã§å³å´ã«æãã¤ã³ã¹ãã¯ã¿ã¼ã§ãã¡ã¤ã«ã¿ããè¦ãã¨ç¢ºèªã§ãã¾ããããã«æãSignatureã¨ãããããã¯ã«Status Verification succeededã¨ããè¨è¼ãæãã¨ç½²åã«æåãã¦ãã¾ãã
é¢é£æ å ±
glTFastã§ãShaderMissing;glTF/PbrMetallicRoughnessãã¨ããã¨ã©ã¼ãçºç
Unity glTFastã§.gltfã.glbãã¡ã¤ã«ãèªã¿è¾¼ãWebGLã¢ããªãä½ã£ãæã以ä¸ã®ã¨ã©ã¼ãçºçãã¾ããã
ShaderMissing;glTF/PbrMetallicRoughness
glTF/PbrMetallicRoughnessã¨ããShaderãè¦ã¤ãããªãã¨ããã¨ã©ã¼ã§ãã ã¢ããªå ã§ãã®Shaderã使ã£ã¦ç¡ãçºããã«ãæã«å«ã¾ãã¦ããªãã£ãã®ããªï¼ã¨äºæ³ã
gltFastã§ä½¿ã£ã¦ããShaderã¯ããã±ã¼ã¸ãã©ã«ãå ã®Runtime/Shaderã該å½ãããã§ããã
ãã©ã«ããå³ã¯ãªãã¯ããã¡ãã¥ã¼ã®ä¸ããShow in Explorerãé¸æã
ä»åã¯Built-Inãã¤ãã©ã¤ã³ã使ã£ã¦ããã®ã§(â»1)ãAssetsãã©ã«ãã«Resourcesãã©ã«ããä½æããããã«Built-Inãã©ã«ããã³ãã¼(â»2)ã
â»1 URPãHDRPã使ã£ã¦ãã人ã¯ããã«åããããã®ãé¸æãã¾ãããã
â»2 ä½æ ãã¨ã¯ã¹ããã¼ã©ã¼ããUnityã¨ãã£ã¿ã¸ã®ãã©ãã°ã§ã¯ä¸æãã³ãã¼åºæ¥ãªãã£ãã®ã§ã¨ã¯ã¹ããã¼ã©ã¼ä¸ã§ã³ãã¼ãã¾ããã
ããã§ç¡äºã«ã¨ã©ã¼ç¡ãã表示ããã¾ããã
Unityã§ã®Appleã®Privacy Manifestã¸ã®å¯¾å¿æ¹æ³
Privacy Manifestã¨ã¯ï¼
Privacy Manifestã¨ã¯2024å¹´æ¥ããå°å ¥ãããäºå®ã®Appleã®æ°ãããã©ã¤ãã·ã¼å¯¾çã®ã¢ãããã¼ãã§ãã
App Storeへの提出におけるプライバシー要件のアップデート - 最新ニュース - Apple Developer
ãã®ã¢ãããã¼ãã«ããããã£ã³ã¬ã¼ããªã³ãã«å©ç¨ã§ããæ å ±ã«ã¢ã¯ã»ã¹ãããAPI(â»)ã使ç¨ããå ´åã«ã¯Privacy Manifestã¨ãããã¡ã¤ã«ãä½æããããã§APIãå©ç¨ããçç±ãæ示ããã¨ããã«ã¼ã«ãå°å ¥ããã¾ãã
â»Appleã¯ãã£ã³ã¬ã¼ããªã³ãã®ä½¿ç¨ãç¦æ¢ãã¦ãã¾ããã¦ã¼ã¶ã®ãã©ããã³ã°ã«ã¯ãã£ã³ã¬ã¼ããªã³ãã§ã¯ç¡ããåºåèå¥å(IDFA)ã使ãå¿ è¦ãæãã¾ãã
Xcodeã®ã¡ãã¥ã¼ãã File > New > File⦠ã¨é¸æããResourceã»ã¯ã·ã§ã³ã«æãApp Privacyãé¸æããã¨PrivacyInfo.xcprivacyã¨ãããã¡ã¤ã«ã§ç©ºã®Privacy Manifestãã¡ã¤ã«ãä½æããã¾ãã
Unityã§ã®å¯¾å¿æ¹æ³
Unityã§ã¯ä»¥ä¸ã®ãã¼ã¸ã§ã³ããPrivacy Manifestã«å¯¾å¿ãã¦ãã¾ãããã®çºãUnityã§ã®å¯¾å¿æ¹æ³ã¨ãã¦ã¯è©²å½ã®ãã¼ã¸ã§ã³ã¸ã®ãã¼ã¸ã§ã³ã¢ããã«ãªãã¾ãã ãã以åã®ãã¼ã¸ã§ã³ã使ã£ã¦ããã¸ã§ã¯ããä½æãã¦ããå ´åã«ã¯ãã¼ã¸ã§ã³ã¢ãããå¿ è¦ã«æãã¾ãã
Privacy Manifest ãã¡ã¤ã«ãçæãããæ§ã«ãªã£ããã¼ã¸ã§ã³
Release Noteã«ã¯Added Apple Privacy Manifest support.ã¨è¨è¼ããã¦ãã¾ãã
系統 | ãã¼ã¸ã§ã³ |
---|---|
Unity 2021.xç³» | Unity 2021.3.35f1(2024/2/8ãªãªã¼ã¹) |
Unity 2022.xç³» | Unity 2022.3.18f1(2024/1/20ãªãªã¼ã¹) |
Unity 2023.xç³» | Unity 2023.2.7f1(2024/1/23ãªãªã¼ã¹) |
â»ãã®ãã¼ã¸ã§ã³ã§çæãããPrivacy Manifestãã¡ã¤ã«ã«ã¯ãSystem boot time APIs - 35F9.1ãã®è¨è¼ãæãã¦ãã¾ãããã¡ãã«ã¤ãã¦ã¯Unity 2023.2.13ã2022.3.21ãããã³ 2021.3.36ã§ä¿®æ£äºå®ã¨ã¢ãã¦ã³ã¹ããã¦ãã¾ãã
ãSystem boot time APIs - 35F9.1ãã®è¨è¼æ¼ããä¿®æ£ããã¦ãããã¼ã¸ã§ã³
Release Noteã«ã¯Added missing privacy manifest entry for System Boot time API usage.ã¨è¨è¼ããã¦ãã¾ãã
Unity 2023.2.13f1ã ãã¯Fixed an issue by adding a missing privacy manifest entry for System Boot time API usage.ã¨è¨è¼ããã¦ãã¾ãã
系統 | ãã¼ã¸ã§ã³ |
---|---|
Unity 2021.xç³» | Unity 2021.3.36(2024/3/5ãªãªã¼ã¹) |
Unity 2022.xç³» | Unity 2022.3.21f1(2024/3/5ãªãªã¼ã¹) |
Unity 2023.xç³» | Unity 2023.2.13f1(2024/3/5ãªãªã¼ã¹) |
Unityã«Privacy Manifeståãã®æ©è½ã¨ãã¦è¿½å ãããå 容ã«ã¤ãã¦ã¯ãã¡ãã®ãã¼ã¸(è±èª)ãåç §ä¸ããã
éè¦ãªé¨åãå¼ç¨ãã¦ããã¾ãã
[Available today] Unity Engine core Required Reason Privacy Manifest entries & related Documentation. See them here. This covers Unity Engine coreâs internal usage of Required Reasons APIs. [Available today] Documentation for C# methods that map to Required Reason APIs. If you use one of these, you will need to declare a Reason. See them here. [Available today] Fixes to the Unity Engine core to comply with Required Reasons. We are updating the Engine to use fewer Required Reason APIs. This change is available in Unity 2021.3.34f1, 2022.3.16f1 and 2023.2.5f1 releases. This is an internal change, so it is not mentioned in the release notes. This change requires a Unity Editor update. [Available soon] Solution to incorporate Privacy Manifests coming from Unity plugins, packages and your project. We expect this change to be available in Unity 2021.3.35f1, 2022.3.18f1 and 2023.2.7f1 releases. The release notes will state "Add Apple Privacy Manifest support". This change will require a Unity editor update. [Work in progress] We will sign Unity Engine libraries within UnityFramework. We expect this change to be available in Unity 2021/2022/2023 forthcoming patch releases This change will require a Unity editor update.
(翻訳)
[æ¬æ¥å ¬éãUnity Engineã³ã¢ å¿ é çç± ãã©ã¤ãã·ã¼ãããã§ã¹ãã¨ã³ããªï¼é¢é£ããã¥ã¡ã³ãããã¡ããã覧ãã ãããUnity Engine coreã®Required Reason APIã®å é¨çãªä½¿ç¨æ¹æ³ãã«ãã¼ãã¦ãã¾ãã [æ¬æ¥å ¬éãRequired Reason APIã«å¯¾å¿ããC#ã¡ã½ããã®ããã¥ã¡ã³ãã§ãããããã®ããããã使ç¨ããå ´åã¯ãReasonã宣è¨ããå¿ è¦ãããã¾ãããã¡ããåç §ãã¦ãã ããã [æ¬æ¥å ¬éãRequired Reasonã«å¯¾å¿ããããã®Unity Engineã³ã¢ã®ä¿®æ£ãããå°ãªãRequired Reason APIã使ç¨ããããã«ã¨ã³ã¸ã³ãæ´æ°ãã¦ãã¾ãããã®å¤æ´ã¯Unity 2021.3.34f1ã2022.3.16f1ã2023.2.5f1ã§å©ç¨å¯è½ã§ããããã¯å é¨çãªå¤æ´ã§ããããããªãªã¼ã¹ãã¼ãã«ã¯è¨è¼ããã¦ãã¾ããããã®å¤æ´ã«ã¯Unity Editorã®ã¢ãããã¼ããå¿ è¦ã§ãã [è¿æ¥å ¬éäºå®] Unityãã©ã°ã¤ã³ãããã±ã¼ã¸ãããã¸ã§ã¯ãããã®ãã©ã¤ãã·ã¼ãããã§ã¹ããåãè¾¼ãããã®ã½ãªã¥ã¼ã·ã§ã³ã§ãããã®å¤æ´ã¯Unity 2021.3.35f1ã2022.3.18f1ã2023.2.7f1ãªãªã¼ã¹ã§å©ç¨å¯è½ã«ãªãäºå®ã§ãããªãªã¼ã¹ãã¼ãã«ã¯ãAdd Apple Privacy Manifest supportãã¨è¨è¼ããã¾ãããã®å¤æ´ã«ã¯Unityã¨ãã£ã¿ã®ã¢ãããã¼ããå¿ è¦ã§ãã [ä½æ¥ä¸] UnityFrameworkå ã®Unity Engineã©ã¤ãã©ãªã«ç½²åãã¾ãããã®å¤æ´ã¯ãUnity 2021/2022/2023ã®ä»å¾ã®ããããªãªã¼ã¹ã§å©ç¨å¯è½ã«ãªããã¨ãæå¾ ãã¦ãã¾ãã
ç¾æç¹ã§ã¯ããã«è¨è¼ããã¦ããæ§ã«Unityã¨ãã£ã¿ã§ã¯ãPrivacy Manifestãã¡ã¤ã«ã«ã¤ãã¦æ±ããæ§ã«ãªã£ããã¨ããé¨åã¾ã§å¯¾å¿æ¸ã¿ã§ãç½²åã®ä½æ¥ã«ã¤ãã¦ã¯ä½æ¥ä¸ã§ãã
Unity Engine ã³ã¢ ã©ã¤ãã©ãªã¯ç½²åããå¿ è¦ç¡ããªã£ãæ§ã§ãã
ã¾ããUnityå ¬å¼ããã¥ã¡ã³ãã®ããã« Privacy Manifest ã«ã¤ãã¦ã®æ å ±ã追å ããã¦ããã®ã§ç®ãéãã¦ãããæ¹ãè¯ãã§ãããã
Unity ãçæãã Privacy Manifest ãã¡ã¤ã«ã®å 容ã確èª
Unityã§Xcodeããã¸ã§ã¯ããçæããã¨PrivacyInfo.xcprivacyãå«ã¾ããããã¸ã§ã¯ããä½æããã¾ãããã¡ã¤ã«ãXcodeä¸ã§éãã¨ä»¥ä¸ã®æ§ã«è¡¨ç¤ºããã¾ãã
ãã¡ã¤ã«ãç´æ¥éããå ´åã«ã¯ä»¥ä¸ã®æ§ã«ãªãã¾ãã
<?xml version="1.0" encoding="utf-8"?> <plist version="1.0"> <dict> <key>NSPrivacyAccessedAPITypes</key> <array> <dict> <key>NSPrivacyAccessedAPIType</key> <string>NSPrivacyAccessedAPICategoryDiskSpace</string> <key>NSPrivacyAccessedAPITypeReasons</key> <array> <string>E174.1</string> </array> </dict> <dict> <key>NSPrivacyAccessedAPIType</key> <string>NSPrivacyAccessedAPICategoryUserDefaults</string> <key>NSPrivacyAccessedAPITypeReasons</key> <array> <string>CA92.1</string> </array> </dict> <dict> <key>NSPrivacyAccessedAPIType</key> <string>NSPrivacyAccessedAPICategoryFileTimestamp</string> <key>NSPrivacyAccessedAPITypeReasons</key> <array> <string>0A2A.1</string> <string>C617.1</string> </array> </dict> </array> <key>NSPrivacyCollectedDataTypes</key> <array /> </dict> </plist>
ããã§ä½¿ããã¦ãããã©ã¡ã¼ã¿ã®èª¬æã¯ä»¥ä¸ã®Appleã®å ¬å¼ããã¥ã¡ã³ãã§ç¢ºèªã§ãã¾ãã
Privacy manifest files | Apple Developer Documentation
â»ããã¥ã¡ã³ãã¯ããããã¼ã¸ã ãã§ã¯ç¡ããDescribing data use in privacy manifestsã¨Describing use of required reason APIã確èªãã¾ãããã
主ãªé¨åã«ã¤ãã¦ç¢ºèªãã¦ã¿ã¾ãããã以ä¸ã®é¨åã«æ³¨ç®ãã¦ã¿ã¾ãã
<dict> <key>NSPrivacyAccessedAPIType</key> <string>NSPrivacyAccessedAPICategoryDiskSpace</string> <key>NSPrivacyAccessedAPITypeReasons</key> <array> <string>E174.1</string> </array> </dict>
ãã®é¨åã§ã¯dictã®ä¸ã«keyã¨ãã¦ãNSPrivacyAccessedAPITypeãvalueã¨ãã¦string(æåå)ã§ãAPIã®ã«ãã´ãªããè¨è¿°ããã«ã¼ã«ã«ãªã£ã¦ãã¾ããããã§ã¯NSPrivacyAccessedAPICategoryDiskSpaceãè¨å®ããã¦ãã¾ããAppleã®å ¬å¼ããã¥ã¡ã³ãã§ç¢ºèªããã¨ããã¯ãDisk space APIsãã¨è¨è¼ããã¦ãããã使ç¨å¯è½ãªãã£ã¹ã¯å®¹éã«ã¢ã¯ã»ã¹ããAPIãã®ã«ãã´ãªã ã¨ç¢ºèªã§ãã¾ãã
次ã«keyã¨ãã¦ãNSPrivacyAccessedAPITypeReasonsãæãã¾ãããã®keyã«å¯¾å¿ããvalueã¨ãã¦ã¯ãã¢ããªã API ã使ç¨ããçç±ã示ãæååããé å(array)ã®ä¸ã«string(æåå)ã§è¨è¿°ãã¾ããããã§ã¯E174.1ãè¨è¿°ããã¦ãã¾ããE174.1ã®èª¬ææã¯ããã¡ã¤ã«ãæ¸ãè¾¼ãã®ã«ååãªã¹ãã¬ã¼ã¸ã®ç©ºã容éãæãã確èªããçºãã¨æ¸ããã¦ãã¾ãã
話ãã¾ã¨ããã¨ä½¿ç¨ããAPIã«ã¤ãã¦ãã«ãã´ãªãã¨ããã®APIã使ç¨ããçç±ããè¨è¿°ããå¿ è¦ãæãã解説ããé¨åã§ã¯ä»¥ä¸ã®å 容ãè¨è¿°ãã¦ãã¾ãã
- ã«ãã´ãª ï¼Disk space APIs
- çç±ï¼ãã¡ã¤ã«ãæ¸ãè¾¼ãã®ã«ååãªã¹ãã¬ã¼ã¸ã®ç©ºã容éãæããã確èªããçº
ãªããçç±ã®é¨åã¯é åãªã®ã§1ã¤ã§ãè¤æ°ã§ãè¨å®å¯è½ã§ããå®éã以ä¸ã®æ§ã«è¤æ°è¨å®ãã¦ããç®æãæãã¾ãã
<key>NSPrivacyAccessedAPIType</key> <string>NSPrivacyAccessedAPICategoryFileTimestamp</string> <key>NSPrivacyAccessedAPITypeReasons</key> <array> <string>0A2A.1</string> <string>C617.1</string> </array>
ããã¥ã¡ã³ãã«è¨è¼ããã¦ããå 容ã¨çæãããPrivacy manifestãã¡ã¤ã«ã®å 容ã«å·®ãæã
Unityã®ããã¥ã¡ã³ãã確èªããã¨Unity Engineå ã§ä½¿ç¨ãã¦ããAPIã«é¢ããPrivacy manifest(ãã«ãã´ãªãã¨ãçç±ã)ã確èªã§ãã¾ãã
ãã®æ å ±ã確èªããã¨ãSystem boot time APIs - 35F9.1ãã«ã¤ãã¦ã®é¨åãçæãããPrivacyInfo.xcprivacyã«ã¯å«ã¾ãã¦ãªãäºã確èªã§ãã¾ãã
ãã¡ãã«ã¤ãã¦ã¯ãã©ã¼ã©ã ã®æ稿ã«ããã¨ããã¥ã¡ã³ããæ£ãããPrivacyInfo.xcprivacyã®è¨è¿°ãééã£ã¦ãããã§ããã¾ããç´ãã«ä¿®æ£ãããã§ããããå¾ ã¦ãªãå ´åã¯æåã§è¿½å ãã¾ãããã
Privacy Manifestãã¡ã¤ã«ã®èªä½ä¾
ä¾ã¨ãã¦ããã§ã¯Unityåãã«iOSã®Pluginãèªä½ããã¨ããã·ãã¥ã¨ã¼ã·ã§ã³ãæ³å®ãã¾ãã
ãã®Pluginã®ä¸ã§ã¯ãUIDocumentPickerViewControllerçµç±ã§ãã¡ã¤ã«ã®ã¿ã¤ã ã¹ã¿ã³ãã«ã¢ã¯ã»ã¹ãããã¨ããäºãããã¾ãããã®å ´åã«ã¯ã©ã®æ§ãª Privacy Manifest ãã¡ã¤ã«ãä½æããã®ããèãã¾ãã
ã¾ãã¯ãã¡ã¤ã«ã®ã¿ã¤ã ã¹ã¿ã³ãã«é¢ããäºãªã®ã§NSPrivacyAccessedAPITypeã«è¨å®ããã®ã¯NSPrivacyAccessedAPICategoryFileTimestampã«ãªãã¾ãã
次ã«NSPrivacyAccessedAPITypeReasonsã§è¨å®ããçç±ã«ã¤ãã¦èãã¾ãã
確èªãã¹ãã¯ãã¡ãã®ããã¥ã¡ã³ãã§ãã NSPrivacyAccessedAPICategoryFileTimestamp(File timestamp APIs)ã«ã¯ä»¥ä¸ã®çç±ãé¸æå¯è½ã§ãã
å¤ | 説æ |
---|---|
DDA9.1 | ããã¤ã¹ã使ç¨ãã¦ãã人ã«ãã¡ã¤ã«ã®ã¿ã¤ã ã¹ã¿ã³ãã表示ããããã®çç±ã§ã¢ã¯ã»ã¹ãããæ å ±ã¯ããã¤ã¹å¤ã«éä¿¡ã§ããªãã |
C617.1 | ã¢ã㪠ã³ã³ãããã¢ã㪠ã°ã«ã¼ã ã³ã³ãããã¾ãã¯ã¢ããªã® CloudKit ã³ã³ããå ã®ãã¡ã¤ã«ã®ã¿ã¤ã ã¹ã¿ã³ãããµã¤ãºãã¾ãã¯ãã®ä»ã®ã¡ã¿ãã¼ã¿ã«ã¢ã¯ã»ã¹ã |
3B52.1 | ããã¥ã¡ã³ã ããã«ã¼ ãã¥ã¼ ã³ã³ããã¼ã©ã¼(UIDocumentPickerViewController)ã使ç¨ãããªã©ãã¦ã¼ã¶ã¼ãç¹å¥ã«ã¢ã¯ã»ã¹ã許å¯ãããã¡ã¤ã«ã¾ãã¯ãã£ã¬ã¯ããªã®ã¿ã¤ã ã¹ã¿ã³ãããµã¤ãºãã¾ãã¯ãã®ä»ã®ã¡ã¿ãã¼ã¿ã«ã¢ã¯ã»ã¹ããã |
0A2A.1 | ãµã¼ããã¼ã㣠SDK ãã¢ããªã使ç¨ãããã¡ã¤ã« ã¿ã¤ã ã¹ã¿ã³ã API ã®ã©ããã¼é¢æ°ãæä¾ãã¦ãããã¢ããªãã©ããã¼é¢æ°ãå¼ã³åºãã¨ãã«ã®ã¿ãã¡ã¤ã« ã¿ã¤ã ã¹ã¿ã³ã API ã«ã¢ã¯ã»ã¹ããã |
3B52.1ã該å½ãããã§ããããããè¨å®ãã¾ãã
ãã®æ å ±ãã¾ã¨ããã¨ãã¡ã¤ã«ã®å 容ã¯ä»¥ä¸ã®æ§ã«ãªãã¾ãã
<?xml version="1.0" encoding="utf-8"?> <plist version="1.0"> <dict> <key>NSPrivacyAccessedAPITypes</key> <array> <dict> <key>NSPrivacyAccessedAPIType</key> <string>NSPrivacyAccessedAPICategoryFileTimestamp</string> <key>NSPrivacyAccessedAPITypeReasons</key> <array> <string>3B52.1</string> </array> </dict> </array> </dict> </plist>
ãããPrivacyInfo.xcprivacyã¨ãããã¡ã¤ã«å(â»)ã§ä¿åããAssets/Plugins/iOSã¨ããæ§é ã®ãã©ã«ããä½æããããã«é ç½®ãã¾ãã
â»æ¡å¼µåã.xcprivacyãªãPrivacy Manifestãã¡ã¤ã«ã¨å¤å®ãããã®ã§å®éã«ã¯PrivacyInfoã®é¨åã¯Pluginåãªã©åºå¥ãä»ããããååã使ã£ãæ¹ãè¯ãã§ããããä¿åãããã©ã«ãã«ã¤ãã¦ãAssets/Pluginsã使ãäºãå¯è½ã§ãã
Xcodeããã¸ã§ã¯ãå ã®PrivacyInfo.xcprivacyã確èªããã¨ä»¥ä¸ã®æ§ã«ãã¡ãã¨è¿½å ããã¦ããäºã確èªã§ãã¾ãã
Item2ã®æã«è¿½å ãããã®ã綺éºã§ã¯æãã¾ãããããã§ãè¨è¿°ã«ã¼ã«çã«ã¯OKãªã®ããªï¼
è£è¶³
ç¾ç¶ãXcode(Version 15.2)ã§ãGenerate Privacy Reportããå®è¡ããæã«ç©ºç½ã®(ä½ãè¨è¿°ããã¦ããªã)PDFãçæããã¾ãã Flutterã®Githubã®issueã§ãåãçç¶ãåºã¦ããã¨ã®è¨è¼ãæãçºãç¾ç¶ã¯ãã®æåã«ãªãæ§ã§ãã
ã¨ã©ã¼ãTensor data cannot be read from, use .MakeReadable() to allow reading from tensor.ãã®ä¿®æ£æ¹æ³
GitHubã§é å¸ãããã¦ãUnity Sentisã使ã£ãããã¸ã§ã¯ããå®è¡ãã¦ã¿ãæã以ä¸ã®æ§ãªã¨ã©ã¼ãçºçãã¾ããã
InvalidOperationException: Tensor data cannot be read from, use .MakeReadable() to allow reading from tensor.
調ã¹ã¦ã¿ãã¨åå ã¯ãã¼ã¸ã§ã³ã¢ããæã®ä»æ§å¤æ´ã¿ããã§ãã
åèæ å ± docs.unity3d.com
åºåããããã³ã½ã«ã使ãåã«outputTensor.MakeReadable()ã®æ§ã«MakeReadable()ãå¼ã¶äºã§ç¡äºãåä½ãã¾ããã
ãAI Text Classifierãã使ç¨ã§ããªããªãã¾ãã
OpenAIã®ãµã¤ãã§ã¯ãAI Text Classifierãã¨ããAIãçæããããã¹ããã©ãããå¤å®ãããã¼ã«ãå ¬éãã¦ãã¾ããã
OpenAIãAIãæ¸ããæç« ãã©ããå¤å¥ãããã¼ã« - PC Watch https://pc.watch.impress.co.jp/docs/news/1474899.html
ãããã2023/7/20ã«ç²¾åº¦ãä½ãã¨ããå¤æããå ¬éãåæ¢ãããæ§ã§ãã
æ å ±å openai.com
AI(ChatGPTãªã©)ã«ã¤ãã¦
AIã¯ä¾¿å©ï¼
ChatGPTã便å©ã ã¨è¨ã人ã使ããªãã¨ãã人ãå± ã¾ãã
å®éã«ä½¿ã£ã¦ã¿ãã¨èªåãæ³å®ãã¦ãã以ä¸ã®åçãè²°ããæãå ¨ç¶çå¤ããªåçããããæãæãã¾ãã
ããããããã¯è³ªåã®ä»æ¹ã工夫ããäºã§æ¹åãããäºãå¤ãã§ãããã®è¾ºãã¯ã¤ã³ã¿ã¼ãããã®æ¤ç´¢ã¯ã¼ãã¨åãæ§ãªå°è±¡ãæã£ã¦ãã¾ããä¾ãã°ã¤ã³ã¿ã¼ãããã§ä½ãã«ã¤ãã¦ã®èªªæã調ã¹ããæã«ã¯ãâ¯â¯ã¨ã¯ããæ¤ç´¢ã¯ã¼ãã«ãã¨ã¯ãä»ãã¦æ¤ç´¢ããã¨ãã®ã¯ã¼ãã«ã¤ãã¦ã®è§£èª¬ãã¼ã¸ãè¦ã¤ããããããªãã¨ãããã¯ããã¯ãæãã¾ããåãæ§ã«ChatGPTã«é©ãã質åæã«ããã¨è¯ãçããè¿ã£ã¦ããäºãå¤ãã§ãã
ãChatGPT ããã³ãã ãã¯ããã¯ããªã©ã®æ¤ç´¢ã¯ã¼ãã§æ¤ç´¢ããã¨è¯ã質åæ¹æ³ã«ã¤ãã¦è§£èª¬ãããã¼ã¸ãããã¤ãè¦ã¤ãããã¨æãã¾ããã¾ããChatGPT-4ã§ããªãè½åãä¸ãã£ã¦ããã®ã§ChatGPT-3.5ã®å ´åã«ã¯æ£ããçµæãè¿ãã¦ãããªããããªè³ªåããã¦ãChatGPT-4ã§ã¯æ£ããåçããã¦ãããããæ¹åããã¦ãã¾ãããªã®ã§ãã¡ããæ´»ç¨ããã®ãè¯ãã§ãã
ãªããChatGPT-4ã¯å ¬å¼ãµã¤ãã§ã¯ææã®ãµãã¹ã¯ãªãã·ã§ã³ã«å å ¥ããå¿ è¦ãæãã¾ããChatGPT-4ãæ´»ç¨ãã¦æ§ç¯ããã¦ãããã¤ã¯ãã½ããã®Bingãªã©ã¯ç¡æã§ä½¿ããã®ã§ãã¡ãã§è©¦ãã®ãè¯ãã§ãããã
AIã¯å±éºï¼
以åãAIãã¼ã«ã¯ãªã¹ã¯ãæãã¨ã®ãã¥ã¼ã¹ãæãã¾ããã
ãã¡ãã«ã¤ãã¦ã¯ç¢ºãã«å±éºæ§ã¯æãããã ãã©ä¸æãæãåããä»ãããçµæã«ãªãã¨è¯ããªãã¨ããææ³ãæã¡ã¾ããã
ãããã¤ã³ã¿ã¼ãããã¨åãããªï¼ã¨æã£ã¦ãã¾ãããã¤ã³ã¿ã¼ãããã¯å±éºãã¨è¨ãããã¨ãããã ããã ãã¨ããæè¦ãããããããªãã§ããï¼å®å ¨ã§ããï¼ãã¨ãã両æ¹ã®æè¦ãåºã¦ããã¨æãã¾ãã
ããããå®æ ã¨ãã¦ã¯å±éºã¨æã£ã¦ãã人ãå±éºã¨æããªãããã¤ã³ã¿ã¼ãããã使ã£ã¦ãã人ãå¤ãã®ã§ã¯ç¡ãã§ããããï¼ãããã人ã¯ãå¤ãªãµã¤ãã«è¡ããªãããå¤ãªã¡ã¼ã«ã«ä»ãã¦ããURLã¯éããªãããªã©ãã¤ã³ã¿ã¼ãããã¯å±éºã ããã¨æ³¨æãããªããæ´»ç¨ãã¦ãããã¨æãã¾ãã
ã¾ããå ´æã«ãã£ã¦ã©ãããã使ã£ã¦è¯ãããå¤æããã®å¤§åã ã¨æãã¾ããä»ã§ãåååçºé»æã®å¶å¾¡é¨åã¯å¤ãªæ»æãåããªãæ§ã«ã¤ã³ã¿ã¼ãããã«ã¯æ¥ç¶ãã¦ããªãã§ããããããããã»ã¨ãã©ã®ä¼ç¤¾ã§ä½¿ãPCã¯ã»ãã¥ãªãã£é¢ã«ã¯æ°ãä»ãã対çããã¦ããåæã§ã¤ã³ã¿ã¼ããããæ´»ç¨ãã¦ããã§ããããAIã®æ´»ç¨ã«ã¤ãã¦ããã®æ§ã«å ´é¢å ´é¢ã«æã£ãå®å ¨ã«é æ ®ããåæã¯ãã¡ãã大åãã¨æãã¾ãã
ä»è¡ããã¦ããè°è«ãAIã«å¯¾ãã¦ãåæ§ã«ãå±éºã ããå ¨é¨ç¡ãã§ãã§ã¯ç¡ããå±éºãªé¨åãé¿ããªããæ£ããæ´»ç¨ã§ããæªæ¥ã«ãªãã°è¯ããªã¨æã£ã¦ãã¾ãã
ChatGPTã®ãã¼ã¯ã³(token)ã«ã¤ãã¦æ¤è¨¼
Tokenizer(å ¬å¼ã®ãã¼ã¯ã³æ°ç¢ºèªãã¼ã«)ã使ã£ã¦ã©ããªæåã ã¨ä½ãã¼ã¯ã³ã«ä½ããæ¤è¨¼ã
â»ãGPT-3ãã®è¨å®ã§æ¤è¨¼ãå°æ¥ããGPT-4ãã®è¨å®ãªã©ä»ã®ãã®ã ã¨ã«ã¼ã«ãå¤ããå¯è½æ§ãæãã¾ãã
â»ãã®ã«ã¼ã«ã¨å¤ããæ§ãªãã¿ã¼ã³ãè¦ã¤ããæ¹ã¯ã³ã¡ã³ãæ¬ã«æ¸ãã¦è²°ããã¨å¬ããã§ãã
ãã¼ã«ã®è§£èª¬
ãã®ãã¼ã«ã§ã¯æåã®èæ¯è²ãåãè²ã®ç¯å²ã1ãã¼ã¯ã³ã表ãã¦ãã¾ãã Tokens ã«ãã¼ã¯ã³æ°ã Characters ã«æåæ°ã表示ããã¾ãã
è±èª
ãè±èªãã¯1åèªãåºæ¬1ãã¼ã¯ã³ã
ãredããthreeãã§æ¤è¨¼ã
æåæ°ãå¤ãã¨ãã¼ã¯ã³æ°ãå¢ããäºãæãããããã4æåã§1ãã¼ã¯ã³ãããã
5æå以ä¸ã ã¨å¸¸ã«2ãã¼ã¯ã³ã¨ããããã§ã¯ç¡ããæåæ°ãå¤ãã¦ã1ãã¼ã¯ã³ãªåèªãæãã
ä¸è¬çãªè±èªè¾æ¸ã«è¼ã£ã¦ããä¸ã§ä¸çªé·ãåèªã¨è¨ããã¦ãããPneumonoultramicroscopicsilicovolcanoconiosisãã¯45æåã§15ãã¼ã¯ã³ã
æ¥æ¬èª
ã²ãããª
ãã²ãããªãã¯1æåã1ï½2ãã¼ã¯ã³ã
(å ¨è§)ã«ã¿ã«ã
ãã«ã¿ã«ããã¯1æåãåºæ¬1ãã¼ã¯ã³ã
é·æãå ¥ãã¦ã¿ãã¨æåæ°ãããã¼ã¯ã³æ°ãå°ãªãã¨ããçµæãçºçã
ããè¦ãã¨ãã¼ã¯ãã®æã1ãã¼ã¯ã³æ±ãã«ãªã£ã¦ãã¾ãã
é·é³è¨å·ã¨ãã®å¾ã®æåã¨ã»ããã§ã§1ãã¼ã¯ã³ã¨ããæ³åãæãããã§ãã
ããããªã©ã®å°ããæå(æ¨ã¦ä»®å)ããã®å¾ã®æåã¨ã»ããã§1ãã¼ã¯ã³ã
åè§ã«ã¿ã«ã
ãåè§ã«ã¿ã«ããã¯1æåã3ãã¼ã¯ã³ã
ãï½±ãã¯3ãã¼ã¯ã³ã
â»UTF-8ã§3ãã¤ãã
ãï¾ã(æ¿ç¹)ããï¾ã(åæ¿ç¹)ããããã3ãã¼ã¯ã³ã â»UTF-8ã§ãããã3ãã¤ãã
å ¨è§ã«ã¿ã«ãã®æã¨éãããークãããックãã®å ´åã«ååã®ãã¼ã¯ã³æ°ã«ãªãã¨ããäºã¯ç¡ãã
ã¨ããäºã§ãç¹å¥ãªçç±ãç¡ãéãã¯å ¨è§ã«ã¿ã«ãã使ã£ãæ¹ãè¯ãã§ãããã
æ¼¢å
ãæ¼¢åãã¯1æåãåºæ¬2ï½3ãã¼ã¯ã³(ã¬ã¢æ¼¢åã ã¨ãã以ä¸ã®å ´åã)ã
ãä»æ¥ãããé½éåºçãã¯ãæåæ°x2=ãã¼ã¯ã³æ°ãã§ããããã以å¤ã¯ãæåæ°x3=ãã¼ã¯ã³æ°ãã«ãªã£ã¦ãã¾ãã
ãð ®·ã(ã¤ã¡ãã)ãã𩸽ã(ã»ã£ã)ã ã¨4ãã¼ã¯ã³ã2æåã¨èªèããã¦ããã®ãæ°ã«ãªãã¾ãã
â»UTF-8ã§4ãã¤ãã
渡辺ã®ã辺ãã®ç°ä½åã§ãããéó ãã ã¨7ãã¼ã¯ã³ã«ããªãã3æåã¨èªèããã¦ããã®ãæ°ã«ãªãã¾ãã
â»ã¡ãªã¿ã«UTF-8ã§å¦çãããã¨ããã¨IVSãªã®ã§7ãã¤ãã
çµµæå
ãçµµæåãã¯1æåãåºæ¬2ãã¼ã¯ã³ã
æ§çµµæåã®ãâºãã¯2ãã¼ã¯ã³ã
ã«ã©ã¼çµµæåã®ãðãã2ãã¼ã¯ã³ããªãã2æåã¨èªèã
ãµãã²ã¼ããã¢ã使ã£ã¦ãããð§ð»ã(æããèè²ã®é¡)â»åèãã¼ã¸ã®çµµæåã ã¨10ãã¼ã¯ã³ã«ãªãäºããã³ã¼ããã¤ã³ãã¯1F9D1 1F3FB
ãUTF-8ã§8ãã¤ãã
ãð¨âð©âð¦ã(家æ: ç·æ§ã女æ§ãç·ã®å)â»åèãã¼ã¸ã®å ´åã10ãã¼ã¯ã³ãã³ã¼ããã¤ã³ãã¯1F468 200D 1F469 200D 1F466
ãUTF-8ã§18ãã¤ãã
æ¥æ¬èªã®æç« ã¨è±èªã®æç« ã®æ¯è¼
åãå 容ã§ãæ¥æ¬èªã®å ´åã¯19ãã¼ã¯ã³ãè±èªã®å ´åã¯9ãã¼ã¯ã³ã«ãªãã¾ãããè±æã®æå¾ã®ããªãªãã¯çç¥ãã¦ãåé¡ç¡ãäºãå¤ãã®ã§ããã¾ã§æ»ããã¨8ãã¼ã¯ã³ã¾ã§æ¸ããäºãå¯è½ã§ãããä¸ã ã大ããªéãã§ãã
ChatGPT ã§é·æã®æç« ã使ãããæã ChatGPT API ã使ãæã®ã³ã¹ããæããäºãèããã¨è±èªã§åé¡ç¡ãå ´é¢ã§ã¯è±èªã使ãæ¹ãè¯ãããã§ãã
å ¬å¼ã®æ å ±
Tokenizerã®ãã¼ã¸ã®æ³¨è¨ã
çµé¨åã¨ãã¦ãä¸è¬çãªè±èªã®ããã¹ãã§ã¯ã1ãã¼ã¯ã³ã¯ï½4æåã®ããã¹ãã«ç¸å½ãã¾ããããã¯ããã1åèªã®3/4ã«ç¸å½ãã¾ãï¼ã¤ã¾ã100ãã¼ã¯ã³ï½=75åèªï¼ã
ãã«ããã¼ã¸ããã¼ã¯ã³ã¨ã¯ä½ã§ããï¼ã¾ããã®æ°ãæ¹ã¯ï¼ãã
1 ãã¼ã¯ã³ ~= è±èªã® 4 æå 1 ãã¼ã¯ã³ ~= ¾ ã¯ã¼ã 100 ãã¼ã¯ã³ ~= 75 ã¯ã¼ã ã¾ã 1-2 æ ~= 30 ãã¼ã¯ã³ 1 æ®µè½ ~= 100 ãã¼ã¯ã³ 1,500 ã¯ã¼ã ~= 2048 ãã¼ã¯ã³ ã¦ã§ã¤ã³ã»ã°ã¬ããã¼ã®åè¨ "You miss 100% of the shots you don't take" ã«ã¯ 11 åã®ãã¼ã¯ã³ãå«ã¾ãã¦ãã¾ãã OpenAI ã®æ²ç« ã«ã¯ 476 åã®ãã¼ã¯ã³ãå«ã¾ãã¦ãã¾ãã ç±³å½ç¬ç«å®£è¨ã®è¬æ¬ã«ã¯1,695 åã®ãã¼ã¯ã³ãå«ã¾ãã¦ãã¾ã