0Pricing
Neo4j Graph Database Fundamentals · درس

تضمينات الرسوم البيانية باستخدام GDS

تعلّم كيف ينشئ Graph Data Science تضمينات للعقد تحوّل بنية الرسم البياني إلى متجهات لاستخدامها في تعلّم الآلة.

تضمينات الرسوم البيانية باستخدام GDS درس مجاني في Neo4j Graph Database Fundamentals على CoddyKit. هذا هو الدرس 4 من أصل 4. يمكنك قراءة الدرس كاملاً أدناه مجاناً — ثم تمرن عليه مباشرة في المتصفح باستخدام محرر أكواد مدمج ومدرس ذكاء اصطناعي متاح 24/7. هذا الدرس جزء من مسار التعلم في Neo4j Graph Database Fundamentals، وتقدمك يتزامن عبر الويب وتطبيق CoddyKit. تتضمن دورة Neo4j Graph Database Fundamentals 4 دروس في المجموع.

بعض أجزاء هذا الدرس لم تُترجم بعد وتظهر باللغة الإنجليزية.

From Graphs to Vectors

Machine learning models work with numbers, not graph topology. Graph embeddings convert each node into a fixed-length vector that captures its position and neighborhood.

Why Embeddings Help

Once nodes are vectors, you can feed them into classifiers, clustering, and similarity search. Similar nodes end up close together in vector space.

Projecting a Graph

Embeddings run on an in-memory graph projection in GDS. First project the nodes and relationships you care about.

CALL gds.graph.project(
  'embedGraph',
  'Person',
  'FRIEND'
);

FastRP

FastRP (Fast Random Projection) is a quick, scalable embedding algorithm. It is a great default for large graphs.

CALL gds.fastRP.stream('embedGraph', { embeddingDimension: 128 })
YIELD nodeId, embedding
RETURN gds.util.asNode(nodeId).name AS name, embedding
LIMIT 5;

Node2Vec

Node2Vec uses biased random walks to learn embeddings that balance local and global structure. It is slower but often richer than FastRP.

CALL gds.node2vec.stream('embedGraph', { embeddingDimension: 128, walkLength: 80 })
YIELD nodeId, embedding
RETURN nodeId, embedding
LIMIT 5;

GraphSAGE

GraphSAGE is an inductive method: it learns a function that can embed even new nodes not seen during training, using their features.

Choosing Dimensions

The embedding dimension trades expressiveness for cost. Common values are 64, 128, or 256. Larger is more detailed but heavier.

Writing Embeddings Back

Use the write mode to store embeddings as a node property, so other queries and tools can use them.

CALL gds.fastRP.write('embedGraph', {
  embeddingDimension: 128,
  writeProperty: 'embedding'
});

Using Embeddings for Similarity

With vectors stored, compute cosine similarity between embeddings to find nodes that are structurally alike.

MATCH (a:Person {name: 'Alice'}), (b:Person)
WHERE a <> b
RETURN b.name, gds.similarity.cosine(a.embedding, b.embedding) AS sim
ORDER BY sim DESC LIMIT 5;

Embeddings in ML Pipelines

Embeddings are powerful features for GDS machine learning pipelines: node classification and link prediction both benefit from them.

Choosing an Algorithm

Use FastRP for speed at scale, Node2Vec for richer structure, and GraphSAGE when you must embed unseen nodes.

Quick Check

Test your embeddings knowledge.

Recap

You learned graph embeddings in GDS:

  • Embeddings turn nodes into vectors
  • FastRP is fast and scalable
  • Node2Vec uses biased random walks
  • GraphSAGE handles unseen nodes
  • Write embeddings back and use them in ML pipelines

الأسئلة الشائعة

هل درس «تضمينات الرسوم البيانية باستخدام GDS» مجاني؟

نعم — نص درس «تضمينات الرسوم البيانية باستخدام GDS» كامل متاح مجاناً هنا على الويب. لتمرينه بشكل تفاعلي (محرر أكواد مدمج ومدرس ذكاء اصطناعي متاح 24/7) وفتح باقي دورة Neo4j Graph Database Fundamentals، انتقل إلى CoddyKit PRO. تتضمن دورة Neo4j Graph Database Fundamentals 4 دروس في المجموع.

ماذا ستتعلم في «تضمينات الرسوم البيانية باستخدام GDS»؟

تعلّم كيف ينشئ Graph Data Science تضمينات للعقد تحوّل بنية الرسم البياني إلى متجهات لاستخدامها في تعلّم الآلة. تتمرن على Neo4j Graph Database Fundamentals مع أكواد عملية تشغلها مباشرة في المتصفح، ومدرس ذكاء اصطناعي متاح 24/7 يجيب على أسئلتك أثناء عملك.

هل أحتاج إلى خبرة سابقة لأبدأ Neo4j Graph Database Fundamentals؟

لا تُشترط خبرة سابقة. Neo4j Graph Database Fundamentals على CoddyKit منظم للمبتدئين حتى المتقدمين، لذا يمكنك البدء من هنا أو من البداية والتقدم بسرعتك الخاصة. هذا هو الدرس 4 من أصل 4.

كم من الوقت يستغرق درس «تضمينات الرسوم البيانية باستخدام GDS»؟

معظم دروس CoddyKit تستغرق حوالي 5–10 دقائق. كل منها موجز وتفاعلي، لذا تحرز تقدماً مستمراً وتستأنف من حيث توقفت عبر الويب والتطبيق.

هل يمكنني كتابة وتشغيل أكواد في درس Neo4j Graph Database Fundamentals هذا؟

نعم. كل درس في Neo4j Graph Database Fundamentals يتضمن محرر أكواد مدمج، لذا تكتب وتشغل أكواداً حقيقية مباشرة في متصفحك وتحصل على تعليقات فورية من الذكاء الاصطناعي — بدون إعداد محلي.

جميع الدروس في هذه الدورة

  1. مقدمة إلى مكتبة GDS
  2. تشغيل خوارزميات GDS
  3. مسارات GDS والتعلّم الآلي
  4. تضمينات الرسوم البيانية باستخدام GDS
← العودة إلى Neo4j Graph Database Fundamentals